MySQL encoding issue

Moderator: cah

Post Reply
cah
General of the Army / Fleet Admiral / General of the Air Force
General of the Army / Fleet Admiral / General of the Air Force
Posts: 1336
Joined: Sun Aug 17, 2008 5:05 am

MySQL encoding issue

Post by cah »

After upgrading to MySQL 8.0.26, I started seeing "?" character when querying Chinese contents from command line (mysql command).
I then remember there's something I need to change for mysqld on the server side.

Looking into old notes, I found the setting below needs to be added:

Code: Select all

skip-character-set-client-handshake
In Centos 7, it is added in /etc/my.cnf under [muysqld] section.
In Centos 8/Rocky 8, it needs to be added in /etc/my.cnf.d//etc/my.cnf.d.

After this, mysql command and CGI started to work.
CAH, The Great
Post Reply