aspose file tools*
The moose likes JDBC and the fly likes Problem in updating data to Oracle database in servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Problem in updating data to Oracle database in servlets" Watch "Problem in updating data to Oracle database in servlets" New topic
Author

Problem in updating data to Oracle database in servlets

lisy jessica
Ranch Hand

Joined: Oct 27, 2010
Posts: 47
Hi Everyone,


I am trying to update the records to Oracle 10g database, it is giving me HTTP Status-500 error, java.lang.NullPointerException, This is my servlet

EditData.java




This is the code, please can anyone help me out why am getting this error...I am stuck here...Please help me .

Thanks in advance,
Lissy.
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

What line is your NullPointerException occuring on? The stace trace should tell you.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Tom Reilly
Rancher

Joined: Jun 01, 2010
Posts: 618
Yes, the stack trace would help a lot. (Also point out the line number in the code you posted since the line number reported in the stack trace is probably not the same.)
Otherwise it's just a guess. My guess is one of your request.getParameter() lines is causing the NPE because those can return null and you call toString() on them.
lisy jessica
Ranch Hand

Joined: Oct 27, 2010
Posts: 47


This is the log file

Please help me ...am confused.

Thanks in advance
Lissy.
lisy jessica
Ranch Hand

Joined: Oct 27, 2010
Posts: 47
Hi guys,

Thanks alot for the help...its the problem with request.getParameter...it works now.

Thanks
Lissy.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem in updating data to Oracle database in servlets