The encoding of character data in general databases is latinl, this does not support Chinese
and the character encoding that supports Chinese is utf-8 Andgbk
If you want the tables in the database to display Chinese, you must specify the character encoding when creating the database
##1 create database bb charset=utf8;
or
1 1 create database bb charset=gbk;
A database called bb is created here. Note thatutf8 here does not have -, only utf8 in the database can be omitted without -
Use show create database bb;You can query the character encoding of the database
You can also use show variables like 'character_set%'; after using the database to query the encoding of various characters in the database
The above is the detailed content of How to build a printable Chinese database. For more information, please follow other related articles on the PHP Chinese website!