The Java Developers Almanac 1.4


Order this book from Amazon.

   
Home > List of Packages > java.sql  [73 examples] > Scrollable Result Sets  [6 examples]

e268. Determining If a Result Set Is Scrollable

See also e267 Creating a Scrollable Result Set.
    try {
        // Get type of the result set
        int type = resultSet.getType();
    
        if (type == ResultSet.TYPE_SCROLL_INSENSITIVE
              || type == ResultSet.TYPE_SCROLL_SENSITIVE) {
            // Result set is scrollable
        } else {
            // Result set is not scrollable
        }
    } catch (SQLException e) {
    }

 Related Examples
e266. Determining If a Database Supports Scrollable Result Sets
e267. Creating a Scrollable Result Set
e269. Moving the Cursor in a Scrollable Result Set
e270. Getting the Cursor Position in a Scrollable Result Set
e271. Getting the Number of Rows in a Table Using a Scrollable Result Set

See also: Batching    Connections    Database Meta Data    Deleting Data    Drivers    Importing and Exporting    Inserting and Updating Data    Oracle OBJECTs    Oracle VARRAYs    Procedures and Functions    Retrieving Data    Tables    Updatable Result Sets   


© 2002 Addison-Wesley.