I Have a server that access a database via JDBC, and want to return ResultSets VIA RMI back to the Client.

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.
0 Comments  (click to add your comment)
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

About | Sitemap | Contact