(mysql.info.gz) Charset-table
Info Catalog
(mysql.info.gz) Charset-database
(mysql.info.gz) Charset-defaults
(mysql.info.gz) Charset-column
10.3.3 Table Character Set and Collation
----------------------------------------
Every table has a table character set and a table collation, which may
not be null. The `CREATE TABLE' and `ALTER TABLE' statements have
optional clauses for specifying the table character set and collation:
CREATE TABLE TBL_NAME (COLUMN_LIST)
[DEFAULT CHARACTER SET CHARSET_NAME [COLLATE COLLATION_NAME]]
ALTER TABLE TBL_NAME
[DEFAULT CHARACTER SET CHARSET_NAME] [COLLATE COLLATION_NAME]
Example:
CREATE TABLE t1 ( ... )
DEFAULT CHARACTER SET latin1 COLLATE latin1_danish_ci;
MySQL chooses the table character set and collation thus:
* If both `CHARACTER SET X' and `COLLATE Y' were specified, then
character set X and collation Y.
* If `CHARACTER SET X' was specified without `COLLATE', then
character set X and its default collation.
* Otherwise, the database character set and collation.
The table character set and collation are used as default values if the
column character set and collation are not specified in individual
column definitions. The table character set and collation are MySQL
extensions; there are no such things in standard SQL.
Info Catalog
(mysql.info.gz) Charset-database
(mysql.info.gz) Charset-defaults
(mysql.info.gz) Charset-column
automatically generated byinfo2html