I want to change auto_increment value in mysql. Right now it's 10. I have gone through this question in stackoverflow.
I tried with
SET @@auto_increment_increment=1;
But when I checked that variable by show variable command then my result was like,
SHOW VARIABLES LIKE 'auto_inc%';
+--------------------------+-------+
| Variable_name | Value |
+--------------------------+-------+
| auto_increment_increment | 10 |
| auto_increment_offset | 1 |
+--------------------------+-------+
I am running my server on windows azure. Is that any problem with that?
Try executing this
SET GLOBAL auto_increment_increment =1;
You can also set it on table level
ALTER TABLE yourtable AUTO_INCREMENT = 1;
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.