1. Check the character set of the default installed MySQL mysql> show variables like '%char%'; character_set_database and character_set_server are still latin1 character sets, which means that the tables created by MySQL later are all in latin1 character sets, not utf8, which will cause some trouble. Therefore, it is necessary to modify my.cnf. Be sure to close the MySQL process before modifying my.cnf, otherwise you will encounter the problem that MySQL's sock cannot connect. 2. Close the mysqld background process Control mysqld in the system preferences, avoiding the trouble of finding the installation location of mysqld. Click Stop MySQL Server 3. Modify the mysql configuration file /etc/my.cnf sudo cp /usr/local/mysql/support-files/my-medium.cnf /etc/my.cnf sudo vi /etc/my.cnf [client] section added: default-character-set=utf8 [mysqld] section added: character-set-server=utf8 After the modification is completed, start mysql 4. Check the results: mysql> show variables like '%char%'; Modification completed# You may also be interested in:
|
<<: Summary of Linux operation and maintenance from elementary to advanced knowledge points
>>: JavaScript regular verification password strength implementation method
1. Add the plug-in and add the following configur...
This article example shares the specific code of ...
The error is as follows: Uncaught TypeError: Cann...
Using the UNION Operator union : Used to connect ...
Introduction MySQL provides an EXPLAIN command th...
1. Try to use single column instead of multi-colum...
I started using Linux for development and enterta...
It is very common to use webpack to build single-...
Preface Since the types of the same fields in the...
This article example shares the specific code of ...
Table of contents Overview 1. How to animate a DO...
This article shares with you the specific code of...
1. Find the corresponding nodejs package, refer t...
Table of contents Single Node Diff reconcileSingl...
The previous article introduced how to achieve a ...