Each user session can open multiple cursors up to the limit set by the initialization parameter OPEN_CURSORS.
If the number of open cursors exceeds this limit,oracle will throw the ‘ORA-01000: maximum open cursors exceeded‘ exception or error.
ORA-01000: maximum open cursors exceeded.
To make sure that the number of open cursors doesn’t exceeds the limit as specified in initialization parameter, close the cursors after the use.
For example when we use a Cursor object or resultset object,close it once the operation is over.
When we use JDBC programming ,this error is common. This is because ,the application developer is either missed of not closed the jdbc object used.The objects can be Statements,Result sets or even JDBC database connection objects.
- Oracle ‘ALTER TABLE’ to ADD columns
- CREATE INDEX as part of CREATE TABLE statement.
- Oracle Tables: Create Table as Select
- Oracle Tables: Create table with foreign key constraint
- ‘CREATE TABLE’ : create table with composite primary key