码迷,mamicode.com
首页 > 其他好文 > 详细

查看和修改表的auto_increment

时间:2018-06-14 21:03:18      阅读:164      评论:0      收藏:0      [点我收藏+]

标签:select   table   数据库   schema   sel   for   inf   val   lte   

表的基本信息都保存在information_schema数据库的tables表中

select auto_increment from information_schema.tables where table_schema=db name and table_name=table name;

 

alter table table_name auto_increment=new value

 

查看和修改表的auto_increment

标签:select   table   数据库   schema   sel   for   inf   val   lte   

原文地址:https://www.cnblogs.com/bibiafa/p/9184195.html

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