Sybase does not seem to support CachedRowSet, so I'm looking for an alternative.
What I need to do is get a ResultSet, load this into an equivelent of a CachedRowSet, and close the ResultSet/Statement/Connection.
Once 'cached', I need to be able to get at the data(obviously!), but I don't have any need to update this data.
Any pointers would be gratefully received, especially pointers to example code.
Isn't CachedRowSet and extension supplied by Sun. You just download the Jar file from their web site.
When you want a CachedRow set you just create one and populate it from the normal ResultSet you obtained from executing your SQL statement.
CachedRowSet is an extension (which I have), but it doesn't work with JConnect (the sybase JDBC driver).
Sybase haven't implemented it as it wasn't in the JDBC 2 specification. They say they may implement it in the future, but they've not guaranteed it.
I think I've now found an alternative, which is a TabularResults.ResultSet. This is a Sybase proprietry class which seems to offer similar functionality to CachedRowSet. I've given it a quick test, and it seems to work as I want.
Can u tell me exactly whats the concept of using CRS..What i understood is with normal ResultSet the connection to DataBase is maintained ..SO i am utilizing the coonection irresoective of any needs..where as in CRS i retrieve the record adn the connection is released to connection Pool.
If this is the reason wasnt this basic requirement taken care before
second advantage is U can update the result set in CSR and then after u have made all the changes u can update it in the backend...unlike in ResultSet where i need to write SQL query..
Are there any other advantage..Am i getting the concept right