This view indicates which tables have
AUTO_INCREMENT columns and provides
information about those columns, such as the current and
maximum column values and the usage ratio (ratio of used to
possible values). By default, rows are sorted by descending
usage ratio and maximum column value.
Tables in these schemas are excluded from view output:
mysql, sys,
INFORMATION_SCHEMA,
performance_schema.
The
schema_auto_increment_columns
view has these columns:
table_schemaThe schema that contains the table.
table_nameThe table that contains the
AUTO_INCREMENTcolumn.column_nameThe name of the
AUTO_INCREMENTcolumn.data_typeThe data type of the column.
column_typeThe column type of the column, which is the data type plus possibly other information. For example, for a column with a
bigint(20) unsignedcolumn type, the data type is justbigint.is_signedWhether the column type is signed.
is_unsignedWhether the column type is unsigned.
max_valueThe maximum permitted value for the column.
auto_incrementThe current
AUTO_INCREMENTvalue for the column.auto_increment_ratioThe ratio of used to permitted values for the column. This indicates how much of the sequence of values is “used up.”