Derby
  1. Derby
  2. DERBY-3300

CREATE INDEX that matches an existing index succeeds with a 01504 warning but does not create the index.

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Minor Minor
    • Resolution: Unresolved
    • Affects Version/s: 10.3.1.4, 10.3.2.1
    • Fix Version/s: None
    • Component/s: SQL
    • Urgency:
      Normal
    • Issue & fix info:
      Repro attached

      Description

      Since CREATE INDEX statement succeeds the index should be created, the warning is useful but doesn't imply the index was not created.
      Derby allows a single physical index to support multiple logical indexes so allowing the index to be created should be fine.

      ij> create table t(i int);
      0 rows inserted/updated/deleted
      ij> create index ti1 on t;
      0 rows inserted/updated/deleted
      ij> create index ti2 on t;
      0 rows inserted/updated/deleted
      WARNING 01504: The new index is a duplicate of an existing index: TI1.
      ij> drop index ti2;
      ERROR 42X65: Index 'TI2' does not exist.

        Issue Links

          Activity

          Gavin made changes -
          Workflow jira [ 12420110 ] Default workflow, editable Closed status [ 12796859 ]
          Rick Hillegas made changes -
          Link This issue is related to DERBY-6269 [ DERBY-6269 ]
          Kathey Marsden made changes -
          Labels derby_triage10_5_2
          Knut Anders Hatlen made changes -
          Link This issue is related to DERBY-789 [ DERBY-789 ]
          Knut Anders Hatlen made changes -
          Link This issue is related to DERBY-991 [ DERBY-991 ]
          Kathey Marsden made changes -
          Field Original Value New Value
          Urgency Normal
          Issue & fix info [Repro attached]
          Daniel John Debrunner created issue -

            People

            • Assignee:
              Unassigned
              Reporter:
              Daniel John Debrunner
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:

                Development