创建索引:
(1)ALTER TABLE table_name ADD INDEX index_name (name) //普通索引
(2)ALTER TABLE table_name ADD UNIQUE (name) //联合索引
(3)ALTER TABLE table_name ADD PRIMARY KEY (name) //主键索引
查看索引:
(1)show index from tblname;
(2)show keys from tblname;
删除索引:
(1)DROP INDEX index_name ON talbe_name
(2)ALTER TABLE table_name DROP INDEX index_name
(3)ALTER TABLE table_name DROP PRIMARY KEY