使用alter修改自增id可以接子查询吗?
例如:
ALTER table tbl_emp auto_increment=(select emp_id from tbl_emp order by emp_id desc limit 1);
是错误的。
但
ALTER table tbl_emp auto_increment=1000 ```是正确的。
auto_increment不允许接子查询来赋值的