Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Error returned

  1. #1
    Junior Member
    Join Date
    Oct 2010
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Error returned

    Hello,

    I am using MySQL Server 5.0 with Apache Tomcat 5.5 and Eclipse SDK 3.2 to run my program. My program uses Java coding language. However, while running the program I received this error,

    java.lang.NullPointerException 
    at com.mysql.jdbc.Connection.registerStatement(Connection.java:4789) 
    at com.mysql.jdbc.Statement.<init>(Statement.java:264) 
    at com.mysql.jdbc.Connection.createStatement(Connection.java:2964) 
    at com.mysql.jdbc.Connection.createStatement(Connection.java:2944) 
    at org.apache.tomcat.dbcp.dbcp.DelegatingConnection.createStatement(DelegatingConnection.java:161) 
    at org.apache.tomcat.dbcp.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.createStatement(PoolingDataSource.java:204) 
    at bgoc.com.dbConn.Conn.execSQL(Conn.java:196) 
    at bgoc.webaccs.MaintainMenu.checkProgQty(MaintainMenu.java:301) 
    at bgoc.webaccs.MaintainMenu.getUserAppl(MaintainMenu.java:271) 
    at bgoc.webaccs.MenuGroup.createUserMenu(MenuGroup.java:248) 
    at bgoc.webaccs.MenuGroup.getUserMenu(MenuGroup.java:225) 
    at bgoc.webaccs.MenuGroup.getUserProgramAppl(MenuGroup.java:68) 
    at bgoc.webaccs.UserInfo.chkPageAndTyp(UserInfo.java:94) 
    at bgoc.webaccs.UserInfo.chkPage(UserInfo.java:59) 
    at org.apache.jsp.authorization.materialRequest.qo_005fnewreq_jsp._jspService(qo_005fnewreq_jsp.java:111) 
    at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97) 
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) 
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332) 
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) 
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264) 
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802) 
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252) 
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173) 
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213) 
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178) 
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) 
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) 
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107) 
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) 
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869) 
    at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664) 
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527) 
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80) 
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684) 
    at java.lang.Thread.run(Unknown Source)


    I have no idea what is causing it. Does anyone have any idea of what are the possible causes of this error like lack of memory, connections or some xml settings? Thanks in advance.


  2. #2
    Administrator copeg's Avatar
    Join Date
    Oct 2009
    Location
    US
    Posts
    5,318
    Thanks
    181
    Thanked 833 Times in 772 Posts
    Blog Entries
    5

    Default Re: Error returned

    Please post the source code which causes this error. It is guesswork to determine the cause of the exception based upon the stack trace alone.

Similar Threads

  1. Replies: 1
    Last Post: March 31st, 2010, 09:42 PM
  2. how to reuse method returned string ??
    By zeeshanmirza in forum Collections and Generics
    Replies: 7
    Last Post: September 4th, 2009, 03:54 PM