Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
Java
persistent resultsets after connection is closed
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
[QUOTE="Bjorn Abelli, post: 634925"] So, I'll give you the same comments here as in c.l.j.databases.. ;-) IMHO I still believe that is a better newsgroup to post such questions in... That would be the common approach, to form the results into a "disconnected" collection, not necessarily "beans" though. The problem is rather that the ResultSet itself is more of a "cursor" connected to the result still in the database. Hence, you can't close the connection without also closing the cursor. As you already have done... ;-) Though I try to design another layer between the business logic and the layer where the actual Connections and ResultSets appear, i.e. to put all relevant info into other types of collections to work with in the business layer (Hashtables, ArrayLists, etc). I'm not exactly sure what you're looking for, but you could look into if your drivers support RowSets. [URL]http://java.sun.com/j2se/1.5.0/docs/api/javax/sql/RowSet.html[/URL] ...and possibly especially CachedRowsets [URL]http://java.sun.com/j2se/1.5.0/docs/api/javax/sql/rowset/CachedRowSet.html[/URL] // Bjorn A [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
Java
persistent resultsets after connection is closed
Top