我正在使用 Hiedisql V9.2。
我设置了默认服务器character-set is utfmb4
,collation is utf8mb4_unicode_ci
但在创建存储过程后仍然显示collation_connection =utf8mb4_general_ci
。
下面是服务器 my.ini 设置。
[client]
default-character-set = utf8mb4
[mysql]
default-character-set = utf8mb4
[mysqld]
init_connect = 'SET NAMES utf8mb4'
collation-server = utf8mb4_unicode_ci
character-set-server=utf8mb4
显示变量,其中 Variable_name LIKE 'character_set_%' OR Variable_name LIKE 'collation%';
+--------------------------+--------------------+
| Variable_name | Value |
+--------------------------+--------------------+
| character_set_client | utf8mb4 |
| character_set_connection | utf8mb4 |
| character_set_database | utf8mb4 |
| character_set_filesystem | binary |
| character_set_results | utf8mb4 |
| character_set_server | utf8mb4 |
| character_set_system | utf8 |
| collation_connection | utf8mb4_unicode_ci |
| collation_database | utf8mb4_unicode_ci |
| collation_server | utf8mb4_unicode_ci |
+--------------------------+--------------------+
创建存储过程后仍然显示collation_connection=utf8mb4_general_ci
。
SHOW PROCEDURE STATUS where name LIKE 'ProcName'
+----------+----------------------+----------------------+--------------------+
| Name | character_set_client | collation_connection | Database Collation |
+----------+----------------------+----------------------+--------------------+
| ProcName | utf8mb4 | utf8mb4_general_ci | utf8mb4_unicode_ci |
+----------+----------------------+----------------------+--------------------+
那么,如何解决collation_connection=utf8mb4_general_ci
问题。
我想要collation_connection=utf8mb4_unicode_ci
。