Derby
  1. Derby
  2. DERBY-1457

lang/triggerGeneral.sql fails intermittently

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Duplicate
    • Affects Version/s: 10.2.1.6, 10.3.1.4
    • Fix Version/s: None
    • Component/s: Test
    • Labels:
      None
    • Environment:
    • Bug behavior facts:
      Regression Test Failure

      Description

      This failure seems to be intermittent. The diff is:

          • Start: triggerGeneral jdk1.3.1 subset - 2.1 derbyall:derbylang 2006-06-26 09:18:19 ***
            941 del
            < DERBY-388 Test Passed.
            941a941,950
            > ERROR 38000: The exception 'SQL Exception: A SAVEPOINT with the passed name already exists in the current transaction.' was thrown while evaluating an expression.
            > ERROR 3B501: A SAVEPOINT with the passed name already exists in the current transaction.
            > ij> – Derby-85: It turns out that if a table t1 exists in a non-default schema
            > – and the default schema (e.g., "SOMEUSER") doesn't exist yet (because no
            > – objects have been created in that schema), then attempts to create a
            > – trigger on t1 using its qualified name will lead to a null pointer
            > – exception in the Derby engine.
            > connect 'wombat;user=someuser';
            > ij(CONNECTION1)> autocommit off;
            > ij(CONNECTION1)> create table myschema.mytable (i int);
            943,951d951
            < ij> – Derby-85: It turns out that if a table t1 exists in a non-default schema
            < – and the default schema (e.g., "SOMEUSER") doesn't exist yet (because no
            < – objects have been created in that schema), then attempts to create a
            < – trigger on t1 using its qualified name will lead to a null pointer
            < – exception in the Derby engine.
            < connect 'wombat;user=someuser';
            < ij(CONNECTION1)> autocommit off;
            < ij(CONNECTION1)> create table myschema.mytable (i int);
            < 0 rows inserted/updated/deleted
            Test Failed.
          • End: triggerGeneral jdk1.3.1 subset - 2.1 derbyall:derbylang 2006-06-26 09:18:52 ***

      Stack trace of failure is:
      ERROR 3B501: A SAVEPOINT with the passed name already exists in the current transaction.
      at java.lang.Throwable.<init>(Throwable.java)
      at java.lang.Throwable.<init>(Throwable.java)
      at org.apache.derby.iapi.error.StandardException.<init>(StandardException.java:83)
      at org.apache.derby.iapi.error.StandardException.<init>(StandardException.java:72)
      at org.apache.derby.iapi.error.StandardException.newException(StandardException.java:294)
      at org.apache.derby.impl.store.raw.xact.Xact.setSavePoint(Xact.java:1420)
      at org.apache.derby.impl.store.access.RAMTransaction.setSavePoint(RAMTransaction.java:1997)
      at org.apache.derby.impl.sql.conn.GenericStatementContext.setSavePoint(GenericStatementContext.java:257)
      at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java)
      at org.apache.derby.impl.sql.execute.GenericTriggerExecutor.executeSPS(GenericTriggerExecutor.java)
      at org.apache.derby.impl.sql.execute.RowTriggerExecutor.fireTrigger(RowTriggerExecutor.java:110)
      at org.apache.derby.impl.sql.execute.TriggerEventActivator.notifyEvent(TriggerEventActivator.java:277)
      at org.apache.derby.impl.sql.execute.UpdateResultSet.fireAfterTriggers(UpdateResultSet.java:825)
      at org.apache.derby.impl.sql.execute.UpdateResultSet.open(UpdateResultSet.java:288)
      at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java)
      at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1181)
      at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:584)
      at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:516)
      at org.apache.derbyTesting.functionTests.tests.lang.userDefMethods.derby388(userDefMethods.java:137)
      at org.apache.derby.exe.ac46a08075x010cx1122x5cc3x0000187d3624a5.g0(Unknown Source)
      at java.lang.reflect.AccessibleObject.invokeV(AccessibleObject.java:199)
      at java.lang.reflect.Method.invoke(Method.java:252)
      at org.apache.derby.impl.services.reflect.ReflectMethod.invoke(ReflectMethod.java:45)
      at org.apache.derby.impl.sql.execute.CallStatementResultSet.open(CallStatementResultSet.java:67)
      at org.apache.derby.impl.sql.GenericPreparedStatement.execute(GenericPreparedStatement.java)
      at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(EmbedStatement.java:1181)
      at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:584)
      at org.apache.derby.impl.jdbc.EmbedStatement.execute(EmbedStatement.java:516)
      at org.apache.derby.impl.tools.ij.ij.executeImmediate(ij.java)
      at org.apache.derby.impl.tools.ij.utilMain.doCatch(utilMain.java:433)
      at org.apache.derby.impl.tools.ij.utilMain.go(utilMain.java:310)
      at org.apache.derby.impl.tools.ij.Main.go(Main.java:207)
      at org.apache.derby.impl.tools.ij.Main.mainCore(Main.java:173)
      at org.apache.derby.impl.tools.ij.Main.main(Main.java:75)
      at org.apache.derby.tools.ij.main(ij.java:56)

        Issue Links

          Activity

          Hide
          A B added a comment -

          I saw this same diff using ibm142 on a 10/02/2006 run of derbyall.

          Show
          A B added a comment - I saw this same diff using ibm142 on a 10/02/2006 run of derbyall.
          Hide
          A B added a comment -

          Making updates to reflect the environment in which I most recently saw this test fail.

          Show
          A B added a comment - Making updates to reflect the environment in which I most recently saw this test fail.
          Hide
          Sunitha Kambhampati added a comment -

          Test also fails with ibm1.5 with 10.3.0.0 alpha - (453830) jars.

          Show
          Sunitha Kambhampati added a comment - Test also fails with ibm1.5 with 10.3.0.0 alpha - (453830) jars.
          Hide
          Mike Matrigali added a comment -

          I believe the following error in Suites.all, testDeleteRowWithTriggerChangingRS is the same issue as the
          TriggerGeneral.sql error in this JIRA. I got the following error 1/17/07, trunk, 10.3.0.0 alpha - (497289) on ibm15 jvm:
          1) testDeleteRowWithTriggerChangingRS(org.apache.derbyTesting.functionTests.tests.lang.UpdatableResultSetTest)java.sql.SQLException: A SAVEPOINT with the passed name already exists in the current transaction.
          at org.apache.derby.client.am.SQLExceptionFactory.getSQLException(Unknown Source)
          at org.apache.derby.client.am.SqlException.getSQLException(Unknown Source)
          at org.apache.derby.client.am.ResultSet.deleteRow(Unknown Source)
          at org.apache.derbyTesting.functionTests.tests.lang.UpdatableResultSetTest.testDeleteRowWithTriggerChangingRS(UpdatableResultSetTest.java:1860)
          at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
          at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
          at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
          at org.apache.derbyTesting.junit.BaseTestCase.runBare(BaseTestCase.java:76)
          at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22)
          at junit.extensions.TestSetup$1.protect(TestSetup.java:19)
          at junit.extensions.TestSetup.run(TestSetup.java:23)
          at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22)
          at junit.extensions.TestSetup$1.protect(TestSetup.java:19)
          at junit.extensions.TestSetup.run(TestSetup.java:23)
          at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22)
          at junit.extensions.TestSetup$1.protect(TestSetup.java:19)
          at junit.extensions.TestSetup.run(TestSetup.java:23)
          Caused by: org.apache.derby.client.am.SqlException: A SAVEPOINT with the passed name already exists in the current transaction.
          at org.apache.derby.client.am.Statement.completeExecute(Unknown Source)
          at org.apache.derby.client.net.NetStatementReply.parseEXCSQLSTTreply(Unknown Source)
          at org.apache.derby.client.net.NetStatementReply.readExecute(Unknown Source)
          at org.apache.derby.client.net.StatementReply.readExecute(Unknown Source)
          at org.apache.derby.client.net.NetPreparedStatement.readExecute_(Unknown Source)
          at org.apache.derby.client.am.ResultSet.readDeleteRow(Unknown Source)
          at org.apache.derby.client.am.ResultSet.positionToCurrentRowAndDelete(Unknown Source)
          at org.apache.derby.client.am.ResultSet.deleteRowX(Unknown Source)
          ... 40 more

          Show
          Mike Matrigali added a comment - I believe the following error in Suites.all, testDeleteRowWithTriggerChangingRS is the same issue as the TriggerGeneral.sql error in this JIRA. I got the following error 1/17/07, trunk, 10.3.0.0 alpha - (497289) on ibm15 jvm: 1) testDeleteRowWithTriggerChangingRS(org.apache.derbyTesting.functionTests.tests.lang.UpdatableResultSetTest)java.sql.SQLException: A SAVEPOINT with the passed name already exists in the current transaction. at org.apache.derby.client.am.SQLExceptionFactory.getSQLException(Unknown Source) at org.apache.derby.client.am.SqlException.getSQLException(Unknown Source) at org.apache.derby.client.am.ResultSet.deleteRow(Unknown Source) at org.apache.derbyTesting.functionTests.tests.lang.UpdatableResultSetTest.testDeleteRowWithTriggerChangingRS(UpdatableResultSetTest.java:1860) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at org.apache.derbyTesting.junit.BaseTestCase.runBare(BaseTestCase.java:76) at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22) at junit.extensions.TestSetup$1.protect(TestSetup.java:19) at junit.extensions.TestSetup.run(TestSetup.java:23) at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22) at junit.extensions.TestSetup$1.protect(TestSetup.java:19) at junit.extensions.TestSetup.run(TestSetup.java:23) at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22) at junit.extensions.TestSetup$1.protect(TestSetup.java:19) at junit.extensions.TestSetup.run(TestSetup.java:23) Caused by: org.apache.derby.client.am.SqlException: A SAVEPOINT with the passed name already exists in the current transaction. at org.apache.derby.client.am.Statement.completeExecute(Unknown Source) at org.apache.derby.client.net.NetStatementReply.parseEXCSQLSTTreply(Unknown Source) at org.apache.derby.client.net.NetStatementReply.readExecute(Unknown Source) at org.apache.derby.client.net.StatementReply.readExecute(Unknown Source) at org.apache.derby.client.net.NetPreparedStatement.readExecute_(Unknown Source) at org.apache.derby.client.am.ResultSet.readDeleteRow(Unknown Source) at org.apache.derby.client.am.ResultSet.positionToCurrentRowAndDelete(Unknown Source) at org.apache.derby.client.am.ResultSet.deleteRowX(Unknown Source) ... 40 more
          Hide
          Suresh Thalamati added a comment -

          This test seems to be failing more often than I expected for an intermittant failure. I noticed this today on ibm15.

          ERROR 38000: The exception 'java.sql.SQLException: A SAVEPOINT with the passed name already exists in the current transaction.' was thrown while evaluating an expression.
          > ERROR 3B501: A SAVEPOINT with the passed name already exists in the current transaction.
          > ij> – Derby-85: It turns out that if a table t1 exists in a non-default schema

          Show
          Suresh Thalamati added a comment - This test seems to be failing more often than I expected for an intermittant failure. I noticed this today on ibm15. ERROR 38000: The exception 'java.sql.SQLException: A SAVEPOINT with the passed name already exists in the current transaction.' was thrown while evaluating an expression. > ERROR 3B501: A SAVEPOINT with the passed name already exists in the current transaction. > ij> – Derby-85: It turns out that if a table t1 exists in a non-default schema
          Hide
          Mike Matrigali added a comment -
          Show
          Mike Matrigali added a comment - failed agin in latest trunk, against ibm15 jvm http://people.apache.org/~fuzzylogic/derby_test_results/main/testlog/ibm15/539216-derbyall_diff.txt
          Hide
          Kathey Marsden added a comment -

          Duplicate of DERBY-2808

          Show
          Kathey Marsden added a comment - Duplicate of DERBY-2808
          Hide
          Kristian Waagan added a comment -

          Closing issue.

          Show
          Kristian Waagan added a comment - Closing issue.

            People

            • Assignee:
              Unassigned
              Reporter:
              Deepa Remesh
            • Votes:
              1 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development