Bug #50518 Unable to drop index
Submitted: 21 Jan 2010 17:44 Modified: 21 Feb 2010 17:56
Reporter: Fahad Sherwani Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Server: InnoDB storage engine Severity:S3 (Non-critical)
Version:5.0.45-log Source distribution OS:Linux
Assigned to: CPU Architecture:Any

[21 Jan 2010 17:44] Fahad Sherwani
Description:
I created a BTREE index on  a table as follows 

create index idx_name BTREE on test1(name);

The index was created successfuly BUT if i issue the drop index command it fails with error message

alter table test1 user drop index idx_name;
ERROR 1091 (42000): Can't DROP 'idx_name; check that column/key exists

How to repeat:

create index idx_name BTREE on test1(name);

alter table test1 user drop index idx_name;

Suggested fix:
The index should have been dropped with dropping the column or table
[21 Jan 2010 17:56] Valeriy Kravchuk
What about correct syntax usage:

77-52-24-143:5.0 openxs$ bin/mysql -uroot test
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.0.90-debug Source distribution

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> create table test1(name varchar(100));
Query OK, 0 rows affected (0.00 sec)

mysql> create index idx_name using btree on test1(name);
Query OK, 0 rows affected (0.39 sec)
Records: 0  Duplicates: 0  Warnings: 0

mysql> alter table test1 drop index idx_name;
Query OK, 0 rows affected (0.01 sec)
Records: 0  Duplicates: 0  Warnings: 0

Check http://dev.mysql.com/doc/refman/5.0/en/create-index.html etc
[22 Feb 2010 0:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".