In the MySQL team, we are currently discussing deprecating the
ability to change the collation_database and
character_set_database settings. As part of our plan, mysql
clients will still be able to access these variables, but they
will be read-only.
Introduction
The MySQL manual summarizes these two variables as
saying:
This option is dynamic, but only the server should set this
information. You should not set the value of this variable
manually.
This is to say that usage is already discouraged, but these two
variables originally had a purpose of allowing a DBA to change
the default character-set temporarily for the current session
only. For example:
SET SESSION character_set_database=latin5;
LOAD DATA infile 'foo.txt' ... ;
-- foo.txt is interpreted as if it was in latin5 …
[Read more]