题解 | #创建索引#

创建索引

http://www.nowcoder.com/practice/f2ea9ccf33c740d58576608940981807

create index idx_duration on examination_info(duration);
create unique index uniq_idx_exam_id on examination_info(exam_id);
create fulltext index full_idx_tag on examination_info(tag);

1、方式一:直接添加

create [索引类型] [索引名] on 表名(列名);

2、方式二:更改表结构

alter table 表名 add 索引类型 索引名(列名);

全部评论

相关推荐

不愿透露姓名的神秘牛友
07-23 18:25
点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务