Next AUTO_INCREMENT value
To get the next AUTO_INCREMENT
value from a table run the following query:
SELECT AUTO_INCREMENT
FROM information_schema.TABLES
WHERE TABLE_SCHEMA = "databaseName"
AND TABLE_NAME = "tableName"
To get the next AUTO_INCREMENT
value from a table run the following query:
SELECT AUTO_INCREMENT
FROM information_schema.TABLES
WHERE TABLE_SCHEMA = "databaseName"
AND TABLE_NAME = "tableName"
Leave a comment