Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2009

    Unanswered: Having problem with ResultSet

    Hello Everyone,
    I have an issue with resultset.
    I am executing one query and gettign the resultset and passing that resultset to another method where i am traversing through the resultset.
    When i iterate through the resultset i am getting exception
    my code looks like:

    void methonone(){
    String query="select * from tablenmae";
    Connection.createstatement();//created the connection
    Statement stmt = con.createStatement();//created the statement
    ResultSet rsRows=stmt.executeQuery(query);//getting the result
    // classTwo
    void methodtwo(ResultSet rs){ an exception.

    The exception is : [jcc][t4][10120][10898][3.52.110] Invalid operation: result set is closed. ERRORCODE=-4470, SQLSTATE=null

    I dont really know why the resultset is closed...
    i would really appreciate if some one can help me out...


  2. #2
    Join Date
    Jan 2003
    Provided Answers: 5
    Just handle the result set in the first method. And throw out the second method.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts