本站中文解释
character_set_connection是Mysql参数变量,用于指定客户端在连接服务器时使用的默认字符集,常用来设置接受客户端传输数据的编码格式。
如何设置:
第一种方式:登陆mysql,用set命令,分别设置character_set_connection参数和character_set_results参数
例如:set character_set_connection=utf8;
set character_set_results=utf8;
第二种方式:加参数设置,修改mysql启动脚本,例如:
[mysqld]
character_set_connection=utf8;
character_set_results=utf8;
官方英文解释
character_set_connection
System Variable | character_set_connection |
---|---|
Scope | Global, Session |
Dynamic | Yes |
Type | String |
Default Value | utf8 |
The character set used for literals specified without a
character set introducer and for number-to-string conversion.
For information about introducers, see
Section 10.3.8, “Character Set Introducers”.