进入MySQL,分别查看rejectprj和reviewprj两个表的结构,通过show full columns from <table>,查看其Collation,如下图

解决Illegal mix of collations (latin1_swedish_ci,IMPLICIT) and (gbk_chinese_ci,COERCIBLE) for operatio

其中reviewprj的fhbh为gbk_chinese_ci,而rejectprj的fhbh为latin1_swedish_ci,所以当两表通过fhbh关联时,就会出现以上错误。

 则通过以下命令将rejectprj的fhbh的Collation更改为gbk_chinese_ci。

mysql>alter table rejectprj changecolumn fhbh fhbh varchar(20) character set 'gbk_chinese_ci';

 这样修改后,执行以上SQL命令不会出错了。

alter table tablename convert to character set GBK。

tablename = 你的表的名称

相关文章:

  • 2021-12-20
  • 2022-12-23
  • 2022-02-25
  • 2022-02-23
  • 2021-04-17
  • 2021-12-09
  • 2022-12-23
  • 2021-07-17
猜你喜欢
  • 2022-12-23
  • 2021-10-07
  • 2022-12-23
  • 2022-12-23
  • 2021-11-22
  • 2021-09-29
  • 2022-12-23
相关资源
相似解决方案