Comment 1 for bug 1388555

Revision history for this message
Valerii Kravchuk (valerii-kravchuk) wrote : Re: SET STATEMENT character_set_client, character_set_connection have no effect

This is easy to confirm:

[openxs@centos ~]$ mysql -uroot test
Reading table information for completion of table and column names
You can turn off this feature to get a quicker startup with -A

Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.6.21-70.0 Percona Server (GPL), Release 70.0, Revision 688

Copyright (c) 2009-2014 Percona LLC and/or its affiliates
Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> set names utf8;
Query OK, 0 rows affected (0.00 sec)

mysql> select 'фи';
+------+
| фи |
+------+
| фи |
+------+
1 row in set (0.00 sec)

mysql> set statement character_set_client = latin5 for select 'фи';
+------+
| фи |
+------+
| фи |
+------+
1 row in set (0.00 sec)

mysql> set character_set_client = latin5;
Query OK, 0 rows affected (0.00 sec)

mysql> select 'фи';
+----------+
| �и |
+----------+
| �и |
+----------+
1 row in set (0.00 sec)