DROP/RENAME INDEX needs table qualified name

Bug #833222 reported by Thomas Jones-Low
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Akiban SQL Parser
Fix Released
High
Mike McMahon

Bug Description

The Derby database system assumes indexes are a schema level object (like tables or sequences). The AkServer assumes Indexes are a Table level object (like columns). Group Indexes are attached to the group.

This means that the DROP INDEX and RENAME INDEX statements need to take qualified table names and index names (e.g. schema1.table2.index3) to disambiuate which index is to be dropped/renamed.

Ariel Weil (aweil)
Changed in akiban-sql-parser:
status: New → Triaged
milestone: none → jenia
importance: Undecided → High
assignee: nobody → Mike McMahon (mmcm)
Mike McMahon (mmcm)
Changed in akiban-sql-parser:
status: Triaged → Fix Committed
Revision history for this message
Thomas Jones-Low (tjoneslo) wrote :

I'm changing the status of this bug back to incomplete because the "DROP INDEX" also needs the table qualification ability. This blocks Bug #857735.

Changed in akiban-sql-parser:
status: Fix Committed → Incomplete
Revision history for this message
Mike McMahon (mmcm) wrote :

Is a single identifier the table name (default index on that table) or the index name (some index by that name in the default schema)?

schema.table.index
table.index
index

or

schema.table.index
table.index
table

Neither one seems particularly clear to me.

Revision history for this message
Thomas Jones-Low (tjoneslo) wrote :

The current implementation in IndexDDL is the former, and this makes the most sense to me. There is no "default" index a given table.

So correct form should be:

DROP INDEX [[<schema>.]<table>.]<index>;

Revision history for this message
Nathan Williams (nwilliams) wrote :

Fixed and in trunk at r154

Changed in akiban-sql-parser:
status: Incomplete → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.