tags:

views:

236

answers:

2

hi, i know about what a RowSet is and all; what i would like to know is if it works properly and is accepted already, or if it still has it's bugs and isn't as widely accepted as the classic ResultSet. it looks good to me so far, but i want to hear more experienced views on the subject.

A: 

RowSet

  1. RowSet makes life a lot easier for all JDBC programmers. No more Connection objects, statement objects, just a single RowSet will do everything for you.
  2. Rowsets make it easy to send tabular data over a network. They can also be used to provide scrollable result sets or updatable result sets when the underlying JDBC driver does not support them.
  3. RowSet object follows the JavaBeans model for properties and event notification, it is a JavaBeans component that can be combined with other components in an application.
  4. Rowsets may have many different implementations to fill different needs. These implementations fall into two broad categories, rowsets that are connected and those that are disconnected.

RowSet Tutorial

adatapost
haha, so sorry, i don't mean to be rude and i appreciate your answer, but i think you didn't read my question. i was asking whether it was widely accepted, or it still had criticisms and people still preferred the ResultSet. sorry for the misunderstanding
anonymous
Yes, RowSet is far better than ResultSet. Ofcourse it is correct but there are some situations where we need to use ResultSet only.
adatapost
can you elaborate further when it's more desirable to use a ResultSet? i can't see what ResultSet can do that RowSet can't
anonymous
+1  A: 

I think there are two factors in deciding if you RowSet is right for you:

1) Can you have the whole result in memory? Sometimes you need to parse the result set one row at a time and can't just get the whole thing in memory at once.

2) Have you tested your JDBC driver for the behavior with RowSet?

I think #2 is where you start with your question. The truth is that it is basically implementation dependent if a given RowSet is robust and production ready. In theory, you can use a RowSet implementation from a different vendor than the JDBC driver as well, and that should work as well.

Yishai
+1 for testing the JDBC driver support. 5 years ago when I was learning Java (coming from .net), I was puzzled about the number of bugs in RowSet. Turned out to be the JDBC driver's fault.
Vlagged
well i'm using MySQL so i hope i'm right in assuming that the driver should work properly as both products are from sun...
anonymous