INTERVIEW QUESTIONS
J2EE
JDBC
DETAILS
Question: What is the difference between Resultset and Rowset?
Answer: RowSets are part of JDBC 2.0 API, and there are quite a few implementations to suit your needs (CachedRowSet, JDBCRowSet, WebRowSet). Essentially a row set is a JavaBean that contains database data. The implementation can store the data offline, or it can simply wrap a connection to make a result set look like a JavaBean. You could even use a row set to access data communicating over HTTP to a servlet, which provides the data for the bean.
Submitted by Srinivas Vemula ([email protected])
|
Question:
What is the difference between Resultset and Rowset?
Answer:
RowSets are part of JDBC 2.0 API, and there are quite a few implementations to suit your needs (CachedRowSet, JDBCRowSet, WebRowSet). Essentially a row set is a JavaBean that contains database data. The implementation can store the data offline, or it can simply wrap a connection to make a result set look like a JavaBean. You could even use a row set to access data communicating over HTTP to a servlet, which provides the data for the bean.
Submitted by Srinivas Vemula ([email protected]) Source: CoolInterview.com
A ResultSet maintains a connection to a database and because of that it can’t be serialized and also we cant pass the Resultset object from one class to other class across the network.
RowSet is a disconnected, serializable version of a JDBC ResultSet and also the RowSet extends the ResultSet interface so it has all the methods of ResultSet. The RowSet can be serialized because it doesn’t have a connection to any database and also it can be sent from one class to another across the network. Source: CoolInterview.com
Answered by: nidhi varshney | Date: 9/11/2009
| Contact nidhi varshney
If you have the better answer, then send it to us. We will display your answer after the approval.
Rules to Post Answers in CoolInterview.com:-
- There should not be any Spelling Mistakes.
- There should not be any Gramatical Errors.
- Answers must not contain any bad words.
- Answers should not be the repeat of same answer, already approved.
- Answer should be complete in itself.
|