Derby
  1. Derby
  2. DERBY-5162

CLOB INOUT arg set to NULL by procedure does not preserve NULL value when re-invoked

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 10.8.1.2
    • Fix Version/s: 10.8.1.2
    • Component/s: JDBC, SQL
    • Labels:
      None
    • Issue & fix info:
      Repro attached
    • Bug behavior facts:
      Wrong query result

      Description

      If a procedure sets an INOUT CLOB arg to NULL and is then re-invoked, the NULL is not preserved. Instead, the procedure sees the same CLOB that it saw in the last invocation. This bug was disclosed during the testing of the fix for DERBY-2515. I will attach a repro.

      1. derby-5162-01-aa-restoreToNull.diff
        0.4 kB
        Rick Hillegas
      2. z.java
        6 kB
        Rick Hillegas

        Issue Links

          Activity

          Rick Hillegas created issue -
          Hide
          Rick Hillegas added a comment -

          Attaching z.java, a program which demonstrates the bug.

          Show
          Rick Hillegas added a comment - Attaching z.java, a program which demonstrates the bug.
          Rick Hillegas made changes -
          Field Original Value New Value
          Attachment z.java [ 12474880 ]
          Rick Hillegas made changes -
          Link This issue blocks DERBY-2515 [ DERBY-2515 ]
          Rick Hillegas made changes -
          Assignee Rick Hillegas [ rhillegas ]
          Hide
          Rick Hillegas added a comment -

          Attaching derby-5162-01-aa-restoreToNull.diff. This is a 1-line patch to SQLChar.restoreToNull() which fixes this bug. I will run regression tests. I don't propose to write a separate regression test for this problem. This fix should be covered by the more exhaustive test supplied in derby-2515-01-ac-copyINOUTreturnValues.diff.

          Touches the following file:

          M java/engine/org/apache/derby/iapi/types/SQLChar.java

          Show
          Rick Hillegas added a comment - Attaching derby-5162-01-aa-restoreToNull.diff. This is a 1-line patch to SQLChar.restoreToNull() which fixes this bug. I will run regression tests. I don't propose to write a separate regression test for this problem. This fix should be covered by the more exhaustive test supplied in derby-2515-01-ac-copyINOUTreturnValues.diff. Touches the following file: M java/engine/org/apache/derby/iapi/types/SQLChar.java
          Rick Hillegas made changes -
          Attachment derby-5162-01-aa-restoreToNull.diff [ 12474905 ]
          Rick Hillegas made changes -
          Issue & fix info [Repro attached] [Patch Available, Repro attached]
          Hide
          Rick Hillegas added a comment -

          Tests passed cleanly except for known Heisenbugs. Committed derby-5162-01-aa-restoreToNull.diff at subversion revision 1086798.

          Show
          Rick Hillegas added a comment - Tests passed cleanly except for known Heisenbugs. Committed derby-5162-01-aa-restoreToNull.diff at subversion revision 1086798.
          Rick Hillegas made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Issue & fix info [Repro attached, Patch Available] [Repro attached]
          Fix Version/s 10.8.0.0 [ 12315561 ]
          Resolution Fixed [ 1 ]
          Rick Hillegas made changes -
          Fix Version/s 10.8.1.1 [ 12316356 ]
          Fix Version/s 10.8.1.0 [ 12315561 ]
          Affects Version/s 10.8.1.1 [ 12316356 ]
          Affects Version/s 10.8.1.0 [ 12315561 ]
          Rick Hillegas made changes -
          Affects Version/s 10.8.1.2 [ 12316362 ]
          Affects Version/s 10.8.1.1 [ 12316356 ]
          Fix Version/s 10.8.1.2 [ 12316362 ]
          Fix Version/s 10.8.1.1 [ 12316356 ]
          Gavin made changes -
          Link This issue blocks DERBY-2515 [ DERBY-2515 ]
          Gavin made changes -
          Link This issue is depended upon by DERBY-2515 [ DERBY-2515 ]
          Rick Hillegas made changes -
          Status Resolved [ 5 ] Closed [ 6 ]
          Gavin made changes -
          Workflow jira [ 12608984 ] Default workflow, editable Closed status [ 12802190 ]

            People

            • Assignee:
              Rick Hillegas
              Reporter:
              Rick Hillegas
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development