Forums Register Login

After UPDATE Statement, Null Value is fetched

+Pie Number of slices to send: Send
I made this code which simply fetches the data and each row has a Edit link Besides it...
When i click on Edit, the record appears perfectly, but when i make changes and click on save, it refreshes and shows null values in every Text Box. However, It makes changes to the Table.


This is the Code For EDIT page

+Pie Number of slices to send: Send
OK.

make a commit of first transaction before you fetch with the second statement.

con.commit();
+Pie Number of slices to send: Send
thank you sir but that wont Solve the problem. This problem is combination of Java and SQL.

Initially i thought, it was Servlet only problem, then it became purely SQL problem, and then a Combination.

The complete solution is here

https://coderanch.com/t/510993/Servlets/java/Servlet-Displays-Old-DB-Entries

+Pie Number of slices to send: Send
Can you check the value of s during the refresh?
+Pie Number of slices to send: Send
value of s remains same. When on Display List page, i click on edit and it attaches a parameter "value" which becomes the value of s. Then later on it stays in the servlet as hidden field and keeps passing no matter how many times i refresh it.
+Pie Number of slices to send: Send
Yeah, but is it art? What do you think tiny ad?
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 1751 times.
Similar Threads
Getting Error in code
not able to call the class file?
user authentication and dao
Why am i getting NullPointerException but runs properly
Incrementing value and reusing jsp page
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 06:57:43.