File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JDBC and Relational Databases and the fly likes rs.updateInt() not working. . please help Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "rs.updateInt() not working. . please help" Watch "rs.updateInt() not working. . please help" New topic

rs.updateInt() not working. . please help

vikhyath reddy

Joined: Dec 07, 2008
Posts: 20
Hello everybody... i have a program code which needs to update the fields provided by the user . i am doing something like this.. i have a mysql table which has 27 rows and 20 columns in each row.

String url="jdbc:mysql://localhost:3306/vikh?user=root&password=admin";

rst=stmt.executeQuery("select * from it_21;");

out.print("inside while"); //this is getting displayed

rst.updateInt(3,123445); // the program flow is stopping at this point.


out.print("In while"); // this is not getting displayed


---- rest of the code ------

%> Thanks in advnace

~ Happy coding ~
Masoud Kalali
Ranch Hand

Joined: Jul 08, 2004
Posts: 531

You need to create an update-able ResultSet, something similar to

The ResultSet object will be forward only meaning that you can not go backward in the ResultSet by calling previous() method.

Masoud Kalali
Software Engineer - My Weblog - GlassFish Security
vikhyath reddy

Joined: Dec 07, 2008
Posts: 20
Thanks a lot Masoud ... Im a newbie so learning things ... thanks once again ! : )
I agree. Here's the link:
subject: rs.updateInt() not working. . please help
It's not a secret anymore!