Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Strange problem using CallableStatement, Ref Cursors.

Strange problem using CallableStatement, Ref Cursors.

From: csatk <member21664_at_dbforums.com>
Date: Sat, 04 Jan 2003 10:47:07 +0000
Message-ID: <2347221.1041677227@dbforums.com>

Hi All,

    I have a strange problem using CallableStatement, Ref Cursors and     Stored Procedures.
    I am using Oracle 9i, JDK 1.4, and Oracle Thin JDBC Driver. I have a Oracle Stored Procedure which returns a Ref Cursor. The stored procedure performs select operations over a huge dataset. Now the strange part.
The call to execute, on the callable statement takes a few milliseconds

                callableStatment.execute();
but, the call to retrieve the Cursor from the statement takes about a miunte.
resultSet = ((OracleCallableStatement)callableStatment).getCursor(9);

It almost seems like the retrieval of the cursor is what triggers the querying/population of the cursor in the database.

I would really appreciate it if anyone could tell me as to what is happening here?

Thanks
Satish

--
Posted via http://dbforums.com
Received on Sat Jan 04 2003 - 04:47:07 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US