MySQL is prone to garbled problems when porting data containing Chinese. Many of them appeared when transplanted from mysql4.x to mysql5.x. The default character set for MySQL is Latin1, and many people use the latin1 character set when using mysql4.
At first, the following phenomena were found:mysql> show variables like ' character% '; +--------------------------+------------------- --------------------+| variable_name | Value |+ --------------------
Beginners are often confused. Does mysql's default Character Set latin1 support Chinese? Preliminary analysis shows that, yes, Chinese is indeed supported! (Is a preliminary conclusion, only a preliminary analysis) 1. first take a look at latin1
The most garbled mysql Chinese is the database encoding problem. If our database encoding is the latin1 character set, but we save the gbk directly, Chinese garbled characters may occur, below I have summarized some solutions.
View my instance first
To sum up the problem of MYSQL encoding conversion latin1 to utf8 bitsCN.com
Black noodle
Yesterday I met a PHP website where the database was MYSQL5.1. after The phpmyadmin management of the website, I found that all Chinese characters in the table
Black noodle
Yesterday I met a PHP website where the database was MYSQL5.1. After the phpmyadmin management of the website, I found that all Chinese characters in the table were garbled. After export, the local import was garbled, you cannot view
Look at my example first.
Error resolution for character set
The problems that arise:Mysql> Update Users-> set username= ' Guan Yu '-> where userid=2;ERROR 1366 (HY000): Incorrect string value: ' Xb9xd8xd3xf0 ' for column ' UsernAme ' at row 1
An
First post:Original address:Linux server under File name my.cnfWindows under File name My.iniproblem: When adding Chinese data to the database through the SQL language, the query is garbled. Cause: The original installation database is the default
In fact, this is more boring-the client is the Lantin character set, after MySQL for the U8 character set, Mycat in the middle in the end what role.Again the environment for this verification:Mac OS 10.11.2MySQL 5.6Mycat 1.5OK, start our
Because of the project environment, ibatis is used in Java projects, while ibatis already has an aiscii (iso8859) Data Source. Therefore, MySQL databases must use Latin1 encoding, the mysql client library also uses Latin1 encoding. Normally, the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.