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

Home -> Community -> Usenet -> c.d.o.server -> Re: ORA-01000 max cursors exceeded

Re: ORA-01000 max cursors exceeded

From: <azp74_at_hotmail.com>
Date: 10 Feb 2005 02:49:24 -0800
Message-ID: <1108032564.187943.217670@z14g2000cwz.googlegroups.com>


OK - I have sorted the problem.

My handle for my statements was being allocated for me by my call to OCIStmtPrepare2 - so I could cancel this using OCIStmtFetch2 with nrows = 0 and OCIStmtRelease.

However, my handle for cursors (used explicitly and solely for result sets from stored procedures) was a handle I was allocating myself using OCIHandleAlloc, so calling OCIStmtFetch2 and OCIStmtRelease was a nonsense. I have changed the code which cancels the cursor handles to call OCIHandleFree (followed by an OCIHandleAlloc - since I still need it) - and now I can set my open_cursors to sensible values (as I test I've set it to 10 - for production I think I'll leave it at 50).

I'm not entirely thrilled about having to free and allocate my cursor handle all the time but I will live with it for now.

Thanks for everyone's input and I'm glad I've finally sussed this out!

Cheers
Alex Received on Thu Feb 10 2005 - 04:49:24 CST

Original text of this message

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