美文网首页
2018-09-03MySQL常用命令

2018-09-03MySQL常用命令

作者: dongzhensong | 来源:发表于2018-09-03 10:41 被阅读11次

1.设置某个键自增(以id为例):

alter table test change id  id int AUTO_INCREMENT;

2.修改某个字段编码:

alter table user1 modify name varchar(20) character set utf8;

字段名称为name 字段类型为 varchar(20) 编码设置为utf8

相关文章

网友评论

      本文标题:2018-09-03MySQL常用命令

      本文链接:https://www.haomeiwen.com/subject/twlbwftx.html