• notice
  • Congratulations on the launch of the Sought Tech site

After mysql reload, there is a garbled setting to utf8 can be resolved.

View the current connection system parameters: SHOW VARIABLES LIKE'%char%';

mysql> show variables like'char%';
+--------------------------+----------------
| Variable_name | Value
+--------------------------+----------------
| character_set_client | gbk
| character_set_connection | gbk
| character_set_database | latin1
| character_set_filesystem | binary
| character_set_results | gbk
| character_set_server | latin1
| character_set_system | utf8
| character_sets_dir | C:/

+--------------------------+----------------
8 rows in set (0.00 sec)
mysql>

You can only set the database and server character set to utf8 in the configuration file, otherwise it will not work

On the command line: stop command: net stop mysql

Start command: net start mysql
mysql core configuration file my.ini

[mysql] The main configuration command line client parameters default-character-set=utf8----Affect client, connection, result
[mysqld] Configuration server parameter character-set-server=utf8-----Affect database server

When adding a function function to mysql, first set set global log_bin_trust_function_creators=1; specify the parameters, otherwise the creation will not succeed

Tags

Technical otaku

Sought technology together

Related Topic

0 Comments

Leave a Reply

+