I need to remove a unique key from my mysql table. How can remove that using mysql query.
I tried this but it is not working
alter table tbl_quiz_attempt
For those who don't know how to get index_name
which mentioned in Devart's answer, or key_name
which mentioned in Uday Sawant's answer, you can get it like this:
SHOW INDEX FROM table_name;
This will show all indexes for the given table, then you can pick name of the index or unique key that you want to remove.