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: maximum open cursors exceeded

Re: ORA-01000: maximum open cursors exceeded

From: EdStevens <quetico_man_at_yahoo.com>
Date: 16 Jun 2006 13:27:16 -0700
Message-ID: <1150489636.723959.261480@i40g2000cwc.googlegroups.com>

Oliver Neumann wrote:
> Hi Thomas,
>
> > You have to make sure, you do close all ResultSets and all Statements
> > (even more important, as every Statement maps to a cursor on the server
> > side)
>
> ah right. Thats the point...i hadnt this problem yet due the auto-close and
> i didnt added a larger amount of rows at once yet so the auto.close worked
> fine till now. Looks good now...the script is able to run without problems
> now.
>
>
> Thanks guys for the help,
> oliver

Looks like you've solved the root problem, but just as a pointer on your code.. you don't need a separate statement to get the next seq. num. Just include it in your INSERT statement:

INSERT INTO employees

   VALUES (employees_seq.nextval,

                  'John',
                  'Doe',
                  'jdoe',
                  '555-1212', TO_DATE(SYSDATE) 
                  );
Received on Fri Jun 16 2006 - 15:27:16 CDT

Original text of this message

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