Basic HTML version of Foils prepared May 19 99

Foil 13 Result Sets can be Scrollable

From Overview of JDBC: Java Database Connectivity Basic Information Track Computational Science Course CPS616 -- Spring Semester 1999. by Nancy McCracken,(Sangetta Aggarwal, Meryem Ispirli, Udayan Parvate, Tom Pulikal, Chao-Wei Ou)


1 New in JDBC 2.0 is that the statement can be given one of the scrollable constants: Statement stmt = conn.createStatement (ResultSet.TYPE_SCROLL_SENSITIVE, ResultSet.CONCUR_READ_ONLY);
2 Scrolling can also be insensitive depending on whether you plan to make changes to the Result Set. You can update, insert and delete rows into the result set and it will take place back in the database.
3 A scrollable Result Set, in addition to the method "rs.next", also has a method "rs.previous" to go back rows. You can set the cursor at the end with "rs.afterLast", and you can move the cursor to particular row numbers with "rs.absolute(int)".

in Table To:


© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Mon Jul 5 1999