以下两种方式必须都设置 character set : latin1 collation : latin1_swedish_ci 显示编码方式: show character set 谢谢苏勇老师,我蹭了他的课,嘿嘿 先进行显示,然后进行设置.推荐utf-8(看附件截图) show variables like 'character_set%'; show variables like 'collation%'; 就能看到了编码方式. 也能在创建数据库的时候,就指定编码方式. 例如: CREA
MySQL设置编码 版本mysql-5.6.21-winx64 mysql默认的编码: mysql> SHOW VARIABLES LIKE 'character%'; +--------------------------+---------------------------------------------+ | Variable_name | Value | +--------------
1.设置编码为UTF-8 set character_set_client = utf8; set character_set_server = utf8; set character_set_connection = utf8; set character_set_database = utf8; set character_set_results = utf8; set collation_connection = utf8_general_ci; set collation_databas