File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes BookMark for disconnected resultset Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Databases » JDBC
Reply Bookmark "BookMark for disconnected resultset" Watch "BookMark for disconnected resultset" New topic
Author

BookMark for disconnected resultset

Joe Nguyen
Ranch Hand

Joined: Apr 20, 2001
Posts: 161
When keeping the cursor open, I can page through the resultset to get the the next 10 records or the previous 10 records, but keeping the cursor open is expensive operation. To avoid this, I would like to get a hold of the current record physical address and return a connection back to the pool. Later, using the physical address and a new connection, I can retrieve the previous 10 records. I am not sure whether JDBC provides this capability. If it does, could someone point me to the right direction? Thanks in advance.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 26185
    
  66

Joey,
I don't think it is possible to do this in a database independent way. What database are you using?

For example, in Oracle, you could use the rowid. This uses a hash to get you right back to the row you need.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: BookMark for disconnected resultset
 
Similar Threads
Scrollable ResultSet
problems moving cursor in resultset
Doubt in JDBC
How to return a cursor in DB2
Resultset display