Collation indicates the collation for
nonbinary string columns, or NULL for other
columns. This value is displayed only if you use the
FULL keyword.

The Null field contains
YES if NULL values can be
stored in the column, NO if not.

The Key field indicates whether the column is
indexed:

If Key is empty, the column either is not
indexed or is indexed only as a secondary column in a
multiple-column, nonunique index.

If Key is PRI, the
column is a PRIMARY KEY or is one of the
columns in a multiple-column PRIMARY KEY.

If Key is UNI, the
column is the first column of a UNIQUE
index. (A UNIQUE index permits multiple
NULL values, but you can tell whether the
column permits NULL by checking the
Null field.)

If Key is MUL, the
column is the first column of a nonunique index in which
multiple occurrences of a given value are permitted within
the column.

If more than one of the Key values applies to
a given column of a table, Key displays the
one with the highest priority, in the order
PRI, UNI,
MUL.

A UNIQUE index may be displayed as
PRI if it cannot contain
NULL values and there is no PRIMARY
KEY in the table. A UNIQUE index
may display as MUL if several columns form a
composite UNIQUE index; although the
combination of the columns is unique, each column can still hold
multiple occurrences of a given value.

The Default field indicates the default value
that is assigned to the column. This is NULL
if the column has an explicit default of
NULL, or if the column definition has no
DEFAULT clause.

The Extra field contains any additional
information that is available about a given column. The value is
nonempty in these cases: auto_increment for
columns that have the AUTO_INCREMENT
attribute; on update CURRENT_TIMESTAMP for
TIMESTAMP columns that have the
ON UPDATE CURRENT_TIMESTAMP attribute.

Privileges indicates the privileges you have
for the column. This value is displayed only if you use the
FULL keyword.

Comment indicates any comment the column has.
This value is displayed only if you use the
FULL keyword.

User Comments

When programming in PHP, ASP and the like I for example want to get the values from an "enum"

when querying like:SHOW columns FROM tableif you load the result in an array it will look like this:array([0],[Field],[1],[Type],[2],[Null],[3],[Key],[4],[Default],[5],[Extra])Where the number, [x], gives the same value as the name, [name].

It's convenient to display information about a table, running status, server configurations. However, it is expensive! For example, a simple "SHOW COLUMNS FROM SomeTable" create a disk-based temporary table. Read more about it here: http://bugs.mysql.com/bug.php?id=10210

I would suggest query caching enabled also for this SHOW COLUMNS. Since the table is not gonna change very frequent.

Note that not all privileges are displayed when using FULL. For example, DELETE isn't shown. If you really need to know whether you have a given permission, the best way I know is to try the operation you want to do, and see if you get an error. For DELETE, for example, you can DELETE FROM tbl LIMIT 0.