Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problem in updating data to Oracle database in servlets

 
lisy jessica
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What line is your NullPointerException occuring on? The stace trace should tell you.
 
Tom Reilly
Rancher
Posts: 618
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


This is the log file

Please help me ...am confused.

Thanks in advance
Lissy.
 
lisy jessica
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi guys,

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

Thanks
Lissy.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic