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 -> Re: proc open cursor

Re: proc open cursor

From: Thomas J. Kyte <tkyte_at_us.oracle.com>
Date: Sat, 11 Mar 2000 22:31:20 GMT
Message-ID: <8aehfo$tef$1@nnrp1.deja.com>


In article <38C7A274.21C3891_at_carinthia.com>,   Udo Apolloner <bap_at_carinthia.com> wrote:
> Hi,
>
> in the ( fragment ) of my program below the
> cursor seems to stay open after the "EXEC SQL CLOSE CU;" statement!
> the sqlca.sqlcode is 0 for all statements!
>
> even the sqlplus statement
> select user_name, sql_text from v$open_cursor;
> shows the cursor open at the time the read waits for input.
>
> EXEC SQL declare cu cursor for select * from tbl;
> EXEC SQL open cu ;
> EXEC SQL fetch cu into :result ;
> EXEC SQL close cu ;
> read(1,input,1);
>
> i am using oracle 8.1.5 on linux
>

what is the setting of holdcursor on the pro*c command line. It is normal for pro*c to cache open cursors -- anticipating you will reuse them soon and can avoid the unnecessary overhead of reopening them.

> thanks,
>
> udo
>

--

Thomas Kyte                              tkyte_at_us.oracle.com
Oracle Service Industries
http://osi.oracle.com/~tkyte/index.html --
Opinions are mine and do not necessarily reflect those of Oracle Corp

Sent via Deja.com http://www.deja.com/
Before you buy. Received on Sat Mar 11 2000 - 16:31:20 CST

Original text of this message

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