为啥我使用了SET NAMES gbk,汉字还是乱码呢?
又试了UTF8和latin1,都是乱码,我是在从Windows的文本文件拷贝到Linux的虚拟机的,不知道用哪种编码方式
又试了UTF8和latin1,都是乱码,我是在从Windows的文本文件拷贝到Linux的虚拟机的,不知道用哪种编码方式
2017-06-12
show variables like '%char%';
Variable_name | Value |
+--------------------------+----------------------------+
| character_set_client | utf8 |
| character_set_connection | utf8 |
| character_set_database | utf8 |
| character_set_filesystem | binary |
| character_set_results | utf8 |
| character_set_server | latin1 |
| character_set_system | utf8 |
| character_sets_dir | /usr/share/mysql/charsets/ |
+--------------------------+----------------------------
server,client 的编码需要一致
举报