MYSQL 5.5版本以后就有utf8mb4,utf8mb4是4个长度。
但是但是mysql 6.0 插入语句有utf8mb4后会报错,这就奇怪了。
查阅官网可以看到The new utf8 character set in MySQL 6.0 is similar to
utf8mb3, but its encoding allows up to four bytes per
翻译后:
新UTF8字符集在MySQL 6是类似的
utf8mb3,但其编码允许多达四个字节
意思就是,mysql 6.0 也有utf8mb4 的这种,但是utf8mb3 也能容纳四个字节。说白了,就是插入语句不能用utf8mb4,可以
用utf8mb3 代替