java.sql.SQLException: ORA-01000: maximum open cursors exceeded

Oracle Community | 3004 | 1 decade ago
  1. 0

    maximum open cursors exceeded

    Oracle Community | 1 decade ago | 3004
    java.sql.SQLException: ORA-01000: maximum open cursors exceeded
  2. 0

    oracle max cursors problem

    Oracle Community | 1 decade ago | 3004
    java.sql.SQLException: ORA-01000: maximum open cursors exceeded
  3. 0

    stale db cursors

    Oracle Community | 1 decade ago | 3004
    java.sql.SQLException: ORA-01000: maximum open cursors exceeded
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    When using iterate and NOT iterating through all items, the cursor stays open. When repeating this several times the "maximum open cursors exceeded" - exception occurs. This problem occured in the following situation: We have an import tool, which reads one line from an import-file and queries the database for colliding/overlapping objects. The objects are loaded whit iterate. The first object which doesn't fit the new input throws an exception and so leaves the iterate-loop. There is no function to close the iterator explicitly. This would solve the problem (once the developer is aware of it). My current workaround ist to use query.list().iterator() instead of query.iterate(). But this is only applicable with small resultsets. I'll do an update of Hibernate soon and see if it still occurs. The attached test crashes after 300 iterations. 300 is the open cursor limit for my DB. org.hibernate.exception.GenericJDBCException: could not execute query using iterate at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:91) at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:79) at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43) at org.hibernate.loader.hql.QueryLoader.iterate(QueryLoader.java:420) at org.hibernate.hql.ast.QueryTranslatorImpl.iterate(QueryTranslatorImpl.java:318) at org.hibernate.engine.query.HQLQueryPlan.performIterate(HQLQueryPlan.java:177) at org.hibernate.impl.SessionImpl.iterate(SessionImpl.java:1177) at org.hibernate.impl.QueryImpl.iterate(QueryImpl.java:46) at de.iccs.test.HibernateAbortIterateTest.testAbortIterate(HibernateAbortIterateTest.java:55) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at junit.framework.TestCase.runTest(TestCase.java:154) at junit.framework.TestCase.runBare(TestCase.java:127) at junit.framework.TestResult$1.protect(TestResult.java:106) at junit.framework.TestResult.runProtected(TestResult.java:124) at junit.framework.TestResult.run(TestResult.java:109) at junit.framework.TestCase.run(TestCase.java:118) at junit.framework.TestSuite.runTest(TestSuite.java:208) at junit.framework.TestSuite.run(TestSuite.java:203) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:478) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:344) at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196) Caused by: java.sql.SQLException: ORA-01000: maximum open cursors exceeded at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:305) at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:272) at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:623) at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:181) at oracle.jdbc.driver.T4CPreparedStatement.execute_for_describe(T4CPreparedStatement.java:420) at oracle.jdbc.driver.OracleStatement.execute_maybe_describe(OracleStatement.java:896) at oracle.jdbc.driver.T4CPreparedStatement.execute_maybe_describe(T4CPreparedStatement.java:452) at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:986) at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:2888) at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:2929) at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:139) at org.hibernate.loader.Loader.getResultSet(Loader.java:1669) at org.hibernate.loader.hql.QueryLoader.iterate(QueryLoader.java:397) ... 20 more

    Hibernate JIRA | 1 decade ago | Frederic Leitenberger
    org.hibernate.exception.GenericJDBCException: could not execute query using iterate
  6. 0

    Does Spring JPA support updating parent/child data having composite keys using Oracle?

    Stack Overflow | 2 years ago
    java.sql.SQLException: ORA-01000: maximum open cursors exceeded

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.sql.SQLException

      ORA-01000: maximum open cursors exceeded

      at oracle.jdbc.driver.DatabaseError.throwSqlException()
    2. Oracle jdbc
      T4CPreparedStatement.execute_maybe_describe
      1. oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
      2. oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:305)
      3. oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:272)
      4. oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:623)
      5. oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:181)
      6. oracle.jdbc.driver.T4CPreparedStatement.execute_for_describe(T4CPreparedStatement.java:420)
      7. oracle.jdbc.driver.OracleStatement.execute_maybe_describe(OracleStatement.java:896)
      8. oracle.jdbc.driver.T4CPreparedStatement.execute_maybe_describe(T4CPreparedStatement.java:452)
      8 frames