Need help in my code

M

mory2311

Hi all ,

This is my first project I work in , and I need help to solve a problem
..

I have a method to insert data from JSP page ' form1' into database
then return a number ' X ' from database to another JSP page ' form2 '
..

the problem is : each time I refresh ' form2 ' the number ' X '
increase coz the servlet code excuted and invoke the methode to insert
the same data into DB then return the new value of ' X ' although some
of entered data are defined as primary key or unique fields and should
not be entered twice .

what should I do ??
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,431
Messages
2,571,677
Members
48,796
Latest member
Greg L.

Latest Threads

Top