May 2001
Intermediate to advanced
1088 pages
30h 13m
English
There is another interesting way to update data. You can update items in the result set and then store the updates back into the database. The ResultSet interface contains methods for updating items of various data types. The format of the various update methods is similar to the get methods, in that the update methods take either a numeric column number or a string column name. The second parameter for each update method is the value you want to store in the column. For instance, to change the value of the first _name column, use the following statement:
results.updateString("first_name", "MyName");
When you create your query statement, you must specify a result set type to let the driver know you want to update ...
Read now
Unlock full access