[MySQL 8.0] error: Illegal mix of collations (utf8mb4_general_ci,IMPLICIT) and (utf8mb4_0900_ai_ci,IMPLICIT)

报错:

 SQL 错误 [1267] [HY000]: Illegal mix of collations (utf8mb4_general_ci,IMPLICIT) and (utf8mb4_0900_ai_ci,IMPLICIT) for operation '='

解决方式

ALTER DATABASE your_dbname CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;
set global default_collation_for_utf8mb4 = utf8mb4_general_ci;

posted @ 2024-09-27 09:16  漠孤烟  阅读(12)  评论(0编辑  收藏  举报