• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Ron McLeod
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

clarify updateInt method in ResultSet

 
Greenhorn
Posts: 28
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Can someone tell me why I am not seeing the effect of updateInt on the row in resultSet.
Scenario:
1). I do a query to recieve one record in my resultSet.
2). Display record for user to verify.
3). If user changes a field value, I apply the users change to the field value in the resultSet row via an updateInt() method.
4). I pass the resultSet to a class/method that handles the inserts
5). Method inserts updated record into another table in same Database.
Problem:
Since I am inserting the modifed record into another DB, I don't do the updateRow() method. Instead I do a separate Insert using the modified resultSet. However, the ResultSet isn't reflecting the change. I even attempt to display the ResultSet after doing the updateInt but it doesn't show the change either.
rs.updateInt(<value>,<pos> ;
rs.first();
rs.getString(<value> ;
 
My honeysuckle is blooming this year! Now to fertilize this tiny ad:
Clean our rivers and oceans from home
https://www.kickstarter.com/projects/paulwheaton/willow-feeders
reply
    Bookmark Topic Watch Topic
  • New Topic