August 1999
Intermediate to advanced
1488 pages
72h 53m
English
cursor.insertRow(table)
The insertRow() method of the Cursor object uses an updateable cursor and inserts a new row in the specified table of the cursor object. If the insert was successful, 0 is returned; otherwise, it returns an error code that can be obtained by using the majorErrorCode() and majorErrorMessage() methods of the Connection or database objects.
Note
Depending on your database, you may have to close the current cursor and reopen it if you want to access a newly inserted row. Also, if the next() method has been called on the cursor, any columns you do not specify values for will get the same values as the current row.
Listing 8.33 creates a Cursor object and selects all rows. ...
Read now
Unlock full access