码迷,mamicode.com
首页 > 数据库 > 详细

mysql索引

时间:2015-04-23 11:06:25      阅读:181      评论:0      收藏:0      [点我收藏+]

标签:

1、创建、增加索引
alter table table1 add index ind_id (id);
create index ind_id on table1 (id);
create unique index ind_id on table1 (id);//建立唯一性索引

2、删除索引
drop index idx_id on table1;
alter table table1 drop index ind_id;

mysql索引

标签:

原文地址:http://blog.csdn.net/shienquan/article/details/45217175

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!