tags:

views:

45

answers:

1

I'm trying to inspect my mysql database information_schema to find out the attributes of the columns. I can't find where the details as to which columns are auto_increment. Does anyone know where I can find this info in the information_schema DB?

+4  A: 

see the EXTRA column in the COLUMNS table:

select * from COLUMNS where  TABLE_SCHEMA='yourschema' and TABLE_NAME='yourtable' and EXTRA like '%auto_increment%'
jscoot