MySql修改字符集

修改mysql配置文件my.cnf(windows为my.ini)添加如下内容:


[client]

default-character-set = utf8mb4


[mysql]

default-character-set = utf8mb4

[mysqld]

character-set-client-handshake = FALSE

character-set-server = utf8mb4

collation-server = utf8mb4_unicode_ci

init_connect='SET NAMES utf8mb4'



备注:my.cnf一般在etc/mysql/my.cnf位置。


相关文章:

  • 2022-01-30
  • 2021-11-28
  • 2022-12-23
  • 2021-07-23
猜你喜欢
  • 2022-01-27
  • 2021-11-28
  • 2021-08-07
  • 2021-09-15
  • 2022-01-05
  • 2021-12-08
相关资源
相似解决方案