Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The current variables of MySQL 5.5 is

 show variables like "%char%";
| Variable_name            | Value                      |
| character_set_client     | utf8                       |
| character_set_connection | utf8                       |
| character_set_database   | latin1                     |
| character_set_filesystem | binary                     |
| character_set_results    | utf8                       |
| character_set_server     | latin1                     |
| character_set_system     | utf8                       |
| character_sets_dir       | /usr/share/mysql/charsets/ |
8 rows in set (0.00 sec)

If a client connect to this DB, without specifying charset using such as SET NAMES LATIN1, what charset it would use?

share|improve this question
up vote 0 down vote accepted

character_set_database this will be the default assuming you didn't mention character set while creating the original database.

Update from Comment conversation:
The connection charset for the client will use value of character_set_client. In this specific case utf8.

Ofcourse this affects only how the client handles strings.

share|improve this answer
I mean the connection charset of the client, not creating the database... – Howard May 14 '11 at 5:31
it will then use the value of character_set_client. in this case 'utf8'. Note: this is for the client and has nothing to do with the db. – Software Mechanic May 14 '11 at 5:34

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.