wood burning stoves 2.0*
The moose likes JDBC and the fly likes how to use disconnceted architecture using JDBC in java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "how to use disconnceted architecture using JDBC in java" Watch "how to use disconnceted architecture using JDBC in java" New topic
Author

how to use disconnceted architecture using JDBC in java

Dhiren Lodhia
Greenhorn

Joined: Mar 05, 2008
Posts: 14
Hi every one,

i want to know how can we use disconnected database architecture using JDBC in java. i.e what i mean is something like DataSet in .Net.
when we take data in ResultSet & when i want to take data from ResultSet the database connection has to be OPEN else it gives error.
i want to take data from database onces and then close Connection then use data!!!
I have Heard about class called CachedRowSet,What is that exactly & how to use it??
please give a small & simple example if possible...........

Thanks in Advance


Dhiren Lodhia
SCJP 5.0 (93%)
Shailesh Chandra
Ranch Hand

Joined: Aug 13, 2004
Posts: 1081

Yes, CachedRowset is the answer for you ! You can use the CachedRowset even after closing the connection.

On a quick search on google will give you many results. I recommend you to read this http://www.javaworld.com/javaworld/jw-02-2001/jw-0202-cachedrow.html

Thanks,
Shailesh


Gravitation cannot be held responsible for people falling in love ~ Albert Einstein
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: how to use disconnceted architecture using JDBC in java
 
Similar Threads
Java application Microsoft SQL server
[JPA] Dynamic CreateNativeQuery - getColumnNames (or ResultSet)?
connection to mssql server database
JDBC?
best approach to move data between 2 databases