1. 查看自增值
SELECT Auto_increment FROM information_schema.TABLES WHERE Table_Schema= 'database' AND table_name= 'tableName'
2.设置自增值
alter table 'tableName' AUTO_INCREMENT=0;
3.重置自增值
truncate table `tableName`;
SELECT Auto_increment FROM information_schema.TABLES WHERE Table_Schema= 'database' AND table_name= 'tableName'
alter table 'tableName' AUTO_INCREMENT=0;
truncate table `tableName`;