MySQL Error: Illegal mix of collations for operation 'concat'

Posted 我来乔23

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了MySQL Error: Illegal mix of collations for operation 'concat'相关的知识,希望对你有一定的参考价值。

  在使用concat连接字符串时出现错误:mysql Error: Illegal mix of collations for operation \'concat\'

  原因:字段操作默认为UTF8的编码,应该绝对统一使用UTF-8,而创建数据库时使用了其它编码。

  

    解决方法:在Navicat for MySQL中删除掉原来的数据库,重新新建,新建时设置字符集和排序规则为UTF-8

  

 

以上是关于MySQL Error: Illegal mix of collations for operation 'concat'的主要内容,如果未能解决你的问题,请参考以下文章

mysql union语句报错:Error Code: 1271. Illegal mix of collations for operation ‘UNION‘

mysql 存储过程中报Illegal mix of collations

MySQL的Illegal mix of collationsy异常原因和解决方法

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

Illegal mix of collations (utf8_general_ci,IMPLICIT) and (gbk_chinese_ci,COERCIBLE) for operation &#

mysql5.6修改字符编码,ERR:Illegal mix of collations for operation 'concat'