Hi, I understand that you are trying to retrieve records from DB and have a page where users can insert/update records.
Based on the above understading... Your method of generating new id in the client end is very serious ! The DB integrity is lost ! What if there is more than one user accessing the page and both try to insert a new record ! Both records get the same new id (generated in your client-side) and a PK constraint violation will be thrown while inserting the second record ! Other ways to handle this are as follows: Let the jsp get the highest id value, add one to it and then insert the new record (or) Create a sequence in DB, get the next value of the sequence before insertion, use this value in the insert statement (or) Create a stored procedure which get triggered before an insert operation Regards, Dayanand. -----Original Message----- From: A mailing list about Java Server Pages specification and reference [mailto:[EMAIL PROTECTED]]On Behalf Of VTR Ravi Kumar Sent: Wednesday, September 04, 2002 4:01 PM To: [EMAIL PROTECTED] Subject: Values not updated Hi, I have a jsp page which retrieves some data from database and the users updates or inserts in that table. When the user clicks create new an id is generated which is the next maximum number the user has his values stored against it. If the user again wants to create another new entry then instead of the executing the jsp it brings it from somewhere in the cache in the client end. The problem is if in the browser of the user the option is set to check for new versions of stored pages as automatic and not every visit to the page then the jsp is executed from the cache and the user gets a older display which is not desirable but it is not possible that at the client end the setting in the browser be changed by me. Is there any way to control it. Please help vtr V.T.R.Ravi Kumar Engineer, ITX, Bharat Heavy Electrical Ltd., ===================================================================== Krodhad bhavati Sammoha Sammohat smritivibrahmah Smritivibrahmat buddinaso Buddhinasat pranasyati -Bhagvatgita "Anger results in delusion, delusion leads to loss in memory, memory loss leads to knowledge loss, If knowledge is lost you perish" ===================================================================== =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com =========================================================================== To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST". For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST". Some relevant FAQs on JSP/Servlets can be found at: http://archives.java.sun.com/jsp-interest.html http://java.sun.com/products/jsp/faq.html http://www.esperanto.org.nz/jsp/jspfaq.jsp http://www.jguru.com/faq/index.jsp http://www.jspinsider.com