USE d1; CREATE TABLE t1 ( c1 CHAR(10) ); 

We create a column without specifying its character set and collation. We’re also not specifying a character set and a collation at the table level. In this circumstance, MySQL checks the database level to determine the table settings, which thereafter become the column settings.) Consequently, the character set for column c1  is latin2  and its collation is latin2_czech_ci . 

## 10.3.10 Compatibility with Other DBMSs 

## 10.4 Connection Character Sets and Collations 

For MaxDB compatibility these two statements are the same: 

CREATE TABLE t1 (f1 CHAR( N ) UNICODE); CREATE TABLE t1 (f1 CHAR( N ) CHARACTER SET ucs2); 

A “connection”  is what a client program makes when it connects to the server, to begin a session within which it interacts with the server. The client sends SQL statements, such as queries, over the session connection. The server sends responses, such as result sets or error messages, over the connection back to the client. 

•Connection Character Set and Collation System Variables 

•Impermissible Client Character Sets 

•Client Program Connection Character Set Configuration 

•SQL Statements for Connection Character Set Configuration 

•Connection Character Set Error Handling 

## Connection Character Set and Collation System Variables 

Several character set and collation system variables relate to a client’s interaction with the server. Some of these have been mentioned in earlier sections: 

•The character_set_server  and collation_server  system variables indicate the server character set and collation. See Section 10.3.2, “Server Character Set and Collation” . 

•The character_set_database  and collation_database  system variables indicate the character set and collation of the default database. See Section 10.3.3, “Database Character Set and Collation” . 

Additional character set and collation system variables are involved in handling traffic for the connection between a client and the server. Every client has session-specific connection-related character set and collation system variables. These session system variable values are initialized at connect time, but can be changed within the session. 

Several questions about character set and collation handling for client connections can be answered in terms of system variables: 

•What character set are statements in when they leave the client? 

The server takes the character_set_client  system variable to be the character set in which statements are sent by the client. 

