MySql添加索引的五种方法mysql下载

作者:

1.添加primary key主键索引)

alter   table  表名称   add  primary   key列名);

2.添加unique唯一索引)

alter  table  表名称  add  unique列名);

3.添加index普通索引)

alter  table  表名称  add  index  索引名index_name)  列名);

4.添加fulltext全文索引)

alter  table  表名称  add  fulltext  列名);

5.添加多列索引

alter  table  表名称  add  index  索引名index_name)  列名1,列名2.......);

原文作者:zqzhang2
原文链接:https://blog.csdn.net/zqzhang2/article/details/50729072

评论

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注

站内搜索