The
INFORMATION_SCHEMA COLUMN_PRIVILEGES
Table
1719
INFORMATION_SCHEMA
Name
SHOW
Name
Remarks
NUMERIC_PRECISION
Type
NUMERIC_SCALE
Type
CHARACTER_SET_NAME
COLLATION_NAME
Collation
COLUMN_TYPE
Type
MySQL extension
COLUMN_KEY
Key
MySQL extension
EXTRA
Extra
MySQL extension
PRIVILEGES
Privileges
MySQL extension
COLUMN_COMMENT
Comment
MySQL extension
Notes:
• In
SHOW
, the
Type
display includes values from several different
COLUMNS
columns.
•
ORDINAL_POSITION
is necessary because you might want to say
ORDER BY
ORDINAL_POSITION
. Unlike
SHOW
,
SELECT
does not have automatic ordering.
•
CHARACTER_OCTET_LENGTH
should be the same as
CHARACTER_MAXIMUM_LENGTH
, except for
multi-byte character sets.
•
CHARACTER_SET_NAME
can be derived from
Collation
. For example, if you say
SHOW FULL
COLUMNS FROM t
, and you see in the
Collation
column a value of
latin1_swedish_ci
, the
character set is what is before the first underscore:
latin1
.
The following statements are nearly equivalent:
SELECT COLUMN_NAME, DATA_TYPE, IS_NULLABLE, COLUMN_DEFAULT
FROM INFORMATION_SCHEMA.COLUMNS
WHERE table_name = '
tbl_name
'
[AND table_schema = '
db_name
']
[AND column_name LIKE '
wild
']
SHOW COLUMNS
FROM
tbl_name
[FROM
db_name
]
[LIKE '
wild
']
19.5. The
INFORMATION_SCHEMA COLUMN_PRIVILEGES
Table
The
COLUMN_PRIVILEGES
table provides information about column privileges. This information comes
from the
mysql.columns_priv
grant table.
INFORMATION_SCHEMA
Name
SHOW
Name
Remarks
GRANTEE
'user_name'@'host_name'
value
TABLE_CATALOG
NULL
TABLE_SCHEMA
TABLE_NAME
COLUMN_NAME
PRIVILEGE_TYPE
IS_GRANTABLE
Notes:
Summary of Contents for 5.0
Page 1: ...MySQL 5 0 Reference Manual ...
Page 18: ...xviii ...
Page 60: ...40 ...
Page 396: ...376 ...
Page 578: ...558 ...
Page 636: ...616 ...
Page 844: ...824 ...
Page 1234: ...1214 ...
Page 1427: ...MySQL Proxy Scripting 1407 ...
Page 1734: ...1714 ...
Page 1752: ...1732 ...
Page 1783: ...Configuring Connector ODBC 1763 ...
Page 1793: ...Connector ODBC Examples 1773 ...
Page 1839: ...Connector Net Installation 1819 2 You must choose the type of installation to perform ...
Page 2850: ...2830 ...
Page 2854: ...2834 ...
Page 2928: ...2908 ...
Page 3000: ...2980 ...
Page 3122: ...3102 ...
Page 3126: ...3106 ...
Page 3174: ...3154 ...
Page 3232: ...3212 ...