执行mysql语句报错 Illegal mix of collations……

时间:2019-03-08 17:00:10   收藏:0   阅读:1905

Illegal mix of collations (latin1_swedish_ci,IMPLICIT) and (utf8mb4_general_ci,COERCIBLE) for operation

在数据库执行查找的命令,判断条件含有特殊字符,再执行的时候报了以上错误;

查看字段编码发现是 latin1 字符集的latin1_german1_ci排序规则

修改数据库字段为utf-8编码  再次执行 顺利出现结果

 

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!