• Post Reply Bookmark Topic Watch Topic
  • New Topic

jsp-servlet to access data from datbase

 
Rajubhai Kotwal
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Experts,

I am working on JSP-servlet to create a page which contains couple of editable drop-down list, text fields etc. I am using mysql at back end. I want to access the database in a such a way that I would be able to compare the database with what user has entered. If it matches, whatever user has entered will go in a flat file say txt file and if it is not present in database, error message will be displayed. At the moment I was able to create the UI part. But I am stuck at Submit button. I mean what condition should I write at click event to compare with database. Result sets is what i can see. Any suggestion guys? Any tutorials available about this? Thank you very much.

Best.
 
Javin Paul
Ranch Hand
Posts: 295
Eclipse IDE Firefox Browser Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

you need to query database and based on query result you have to do the processing.

you can delegate this part of code to servlet instead of processing on jsp and can display waiting (if required ) in jsp page.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!