CREATE UNIQUE INDEX index_name ON table_name (first, second);    
http://dev.mysql.com/doc/refman/5.0/en/create-index.html





Questions and answers:
Clink on Option to Answer




1. Add index to the table

  • a) ALTER ... ADD INDEX catg (catg, user_id) UNIQUE
  • b) CREATE UNIQUE INDEX catg ON catg (catg, user_id)


References: