aspose file tools*
The moose likes JDBC and the fly likes How to get the number of rows in a ResultSet Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "How to get the number of rows in a ResultSet" Watch "How to get the number of rows in a ResultSet" New topic
Author

How to get the number of rows in a ResultSet

Rudy Sam
Greenhorn

Joined: May 25, 2005
Posts: 4
Hello,
I'm an intern and I'm trying to get the number of rows from result set in oracle using rs.last() and rs.beforeFirst() methods but I got an error. Could Below is my sample code:


When I run the code I do have the following ERROR Message:



Please could any body Help me out here to figure out how to correct this
OR a possible suggestion?
Any Help would be highly apprecited.
Abhinav Srivastava
Ranch Hand

Joined: Nov 19, 2002
Posts: 349

stmt = con.createStatement(ResultSet.TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_READ_ONLY)
[ May 25, 2005: Message edited by: Jack Ryan ]
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: How to get the number of rows in a ResultSet