I Have a server that access a database via JDBC, and want to return ResultSets VIA RMI back to the Client.
Created Dec 20, 2001
Benoit Quintin Look, as far as I understand it, a resultset really doesn't make ANY sense once serialized out of the JVM it was created in.
You are right, going through your resultset and adding it to a Vector is a decent way of doing it. As in
Connection con;
Statement st;
ResultSet rs = st.executeQuery("query here");
Vector v = new Vector();
while(rs.next) {
v.add(rs.getXXXXX);
}
then close your resultset and serialize the vector.