首页 > 其他 > 详细

centos 7.0 下触发器乱码的解决

时间:2015-03-06 13:54:50      阅读:253      评论:0      收藏:0      [点我收藏+]
[root@iZ62jhlmmZ ~]# uname -a
Linux iZ62jhlmsymZ 3.10.0-123.13.2.el7.x86_64 #1 SMP Thu Dec 18 14:09:13 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
[root@iZ62jhlmmZ ~]# mysql
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 9
Server version: 5.5.41-MariaDB MariaDB Server

修改配置文件

[root@iZ62jhlmmZ ~]# vi /etc/my.cnf.d/server.cnf


在 [mysqld] 下添加
character-set-server = utf8
character-set-filesystem = utf8

保存退出

[root@iZ62jhlmsymZ ~]# service mariadb restart

在 mysql 中

SHOW VARIABLES LIKE ‘character_set_%‘;
SHOW VARIABLES LIKE ‘collation_%‘;

检查结果是否正确

 

centos 7.0 下触发器乱码的解决

原文:http://www.cnblogs.com/diylab/p/4317870.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!