MySql and servlet error (NullPointerException
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   bjorn_boisschot
Posted On:   Sunday, March 10, 2002 01:57 AM

When I try my servlets i get the following exception. Can anyone explain me how to solve this or what this exactly means. java.lang.NullPointerException at Testing.doGet(Testing.java:57) at javax.servlet.http.HttpServlet.service(HttpServlet.java:740) at javax.servlet.http.HttpServlet.service(HttpServlet.java:853) at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405) at org.apache.tomcat.core.Handler.service(Handler.java:287) at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372) at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:812) at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)    More>>

When I try my servlets i get the following exception. Can anyone explain me how to solve this or what this exactly means.


java.lang.NullPointerException
at Testing.doGet(Testing.java:57)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.apache.tomcat.core.ServletWrapper.doService(ServletWrapper.java:405)
at org.apache.tomcat.core.Handler.service(Handler.java:287)
at org.apache.tomcat.core.ServletWrapper.service(ServletWrapper.java:372)
at org.apache.tomcat.core.ContextManager.internalService(ContextManager.java:812)
at org.apache.tomcat.core.ContextManager.service(ContextManager.java:758)
at org.apache.tomcat.service.connector.Ajp12ConnectionHandler.processConnection(Ajp12ConnectionHandler.java:166)
at org.apache.tomcat.service.TcpWorkerThread.runIt(PoolTcpEndpoint.java:416)
at org.apache.tomcat.util.ThreadPool$ControlRunnable.run(ThreadPool.java:501)
at java.lang.Thread.run(Thread.java:484)

   <<Less

Re: MySql and servlet error (NullPointerException

Posted By:   Anonymous  
Posted On:   Sunday, March 10, 2002 02:50 AM

That at at line 74 of your Testing.java file, inside your method doGet(), you are using an object that is null, so you are getting the NullPointerException error.


Regards

About | Sitemap | Contact