JZ0R0: ResultSet has already been closed. - Weblogic

This is a discussion on JZ0R0: ResultSet has already been closed. - Weblogic ; Hi, I'm using WebLogic Server 6.1 SP6 and jConnect (TM) for JDBC(TM)/5.2(Build 21172)/P/EBF9852/JDK12/Fri Oct 26 13:52:51 2001 When the server starts, inside an startUpClass, the aplication executes a select on a table inside a Sybase ASE-12_0 database, when browsing the ...

+ Reply to Thread
Results 1 to 4 of 4

Thread: JZ0R0: ResultSet has already been closed.

  1. JZ0R0: ResultSet has already been closed.


    Hi,

    I'm using WebLogic Server 6.1 SP6 and
    jConnect (TM) for JDBC(TM)/5.2(Build
    21172)/P/EBF9852/JDK12/Fri Oct 26 13:52:51 2001

    When the server starts, inside an startUpClass, the
    aplication executes a select on a table inside a Sybase
    ASE-12_0 database, when browsing the resultset object, I
    randomly get an JZ0R0: ResultSet has already been closed.
    Exception

    Does anyone have experienced something like this



  2. Re: JZ0R0: ResultSet has already been closed.



    Miguel Chavez wrote:

    > Hi,
    >
    > I'm using WebLogic Server 6.1 SP6 and
    > jConnect (TM) for JDBC(TM)/5.2(Build
    > 21172)/P/EBF9852/JDK12/Fri Oct 26 13:52:51 2001
    >
    > When the server starts, inside an startUpClass, the
    > aplication executes a select on a table inside a Sybase
    > ASE-12_0 database, when browsing the resultset object, I
    > randomly get an JZ0R0: ResultSet has already been closed.
    > Exception
    >
    > Does anyone have experienced something like this?


    Hi. I also answered you in the jconnect50 newsgroup but you didn't have
    your email address in that one....

    I'd like to see your jdbc code to be sure. Does your code
    ever do something like this?

    stmt.executeQuery();
    ResultSet rs = stmt.getResultSet();

    Joe Weinstein at BEA

    >
    >



  3. Re: JZ0R0: ResultSet has already been closed.

    Hi. I see the code. That's the problem.
    Do this instead:

    // don't ignore result set returned, else it
    // can be GC()ed and maybe close itself.
    ResultSet resultset = statement.executeQuery(sql);

    String prod_id= "";
    String screen_id = "";
    String obj_desc = "";

    while (resultset.next())
    {
    do whatever...
    }
    resultset.close();


    Miguel Chavez wrote:

    > Hi,
    >
    > I'm using WebLogic Server 6.1 SP6 and
    > jConnect (TM) for JDBC(TM)/5.2(Build
    > 21172)/P/EBF9852/JDK12/Fri Oct 26 13:52:51 2001
    >
    > When the server starts, inside an startUpClass, the
    > aplication executes a select on a table inside a Sybase
    > ASE-12_0 database, when browsing the resultset object, I
    > randomly get an JZ0R0: ResultSet has already been closed.
    > Exception
    >
    > Does anyone have experienced something like this
    >
    >



  4. Re: JZ0R0: ResultSet has already been closed.


    I haven't seen these one.

    Thanks anyway!!!
    Joe Weinstein wrote:
    >Hi. I see the code. That's the problem.
    >Do this instead:
    >
    > // don't ignore result set returned, else it
    > // can be GC()ed and maybe close itself.
    > ResultSet resultset = statement.executeQuery(sql);
    >
    > String prod_id= "";
    > String screen_id = "";
    > String obj_desc = "";
    >
    > while (resultset.next())
    > {
    > do whatever...
    > }
    > resultset.close();
    >
    >
    >Miguel Chavez wrote:
    >
    >> Hi,
    >>
    >> I'm using WebLogic Server 6.1 SP6 and
    >> jConnect (TM) for JDBC(TM)/5.2(Build
    >> 21172)/P/EBF9852/JDK12/Fri Oct 26 13:52:51 2001
    >>
    >> When the server starts, inside an startUpClass, the
    >> aplication executes a select on a table inside a Sybase
    >> ASE-12_0 database, when browsing the resultset object, I
    >> randomly get an JZ0R0: ResultSet has already been closed.
    >> Exception
    >>
    >> Does anyone have experienced something like this
    >>
    >>

    >



+ Reply to Thread