Oracle 5.0 Reference Manual page 2913

Table of Contents

Advertisement

MySQL 5.0 FAQ: MySQL Chinese, Japanese, and Korean Character Sets
because
is a superset of gb2312—but eventually they try to insert a rarer Chinese character and it
gbk
doesn't work. (See Bug #16072 for an example).
Here, we try to clarify exactly what characters are legitimate in
official documents. Please check these references before reporting
• For a complete listing of the
collation:
gb2312
• MySQL's
is in reality "Microsoft code page 936". This differs from the official
gbk
(middle dot),
A1A4
A1AA
• For a listing of gbk/Unicode mappings, see
MICSFT/WINDOWS/CP936.TXT.
• For MySQL's listing of
B.11.2: I have inserted CJK characters into my table. Why does
characters?
This problem is usually due to a setting in MySQL that doesn't match the settings for the application
program or the operating system. Here are some common steps for correcting these types of issues:
• Be certain of what MySQL version you are using.
Use the statement
SELECT VERSION();
• Make sure that the database is actually using the desired character set.
People often think that the client character set is always the same as either the server character set
or the character set used for display purposes. However, both of these are false assumptions. You
can make sure by checking the result of
using this statement:
SELECT character_set_name, collation_name
FROM information_schema.columns
WHERE table_schema = your_database_name
AND table_name = your_table_name
AND column_name = your_column_name;
• Determine the hexadecimal value of the character or characters that are not being displayed
correctly.
You can obtain this information for a column
following query:
SELECT HEX(column_name)
FROM table_name;
is the encoding for the
3F
column. This most often happens because of a problem converting a particular character from your
client character set to the target character set.
• Make sure that a round trip possible—that is, when you select
hexadecimal-value), you obtain
For example, the Japanese Katakana character Pe (ペ') exists in all CJK character sets, and has
the code point value (hexadecimal coding) 0x30da. To test a round trip for this character, use this
query:
SELECT 'ペ' AS `ペ`;
If the result is not also ペ, then the round trip has failed.
characters, ordered according to the
gb2312
(em dash), A6E0-A6F5, and A8BB-A8C0.
http://www.unicode.org/Public/MAPPINGS/VENDORS/
characters, see gbk.
gbk
to determine this.
SHOW CREATE TABLE tablename
column_name
character; this means that
?
literal
/* or SELECT _ucs2 0x30da; */
2893
gb2312
gb2312
SELECT
in the table
is the character actually stored in the
?
literal
as a result.
or gbk, with reference to the
or
bugs.
gbk
gb2312_chinese_ci
for characters
gbk
display them as "?"
or—better yet—by
using the
table_name
(or
_introducer

Advertisement

Table of Contents
loading

This manual is also suitable for:

Mysql 5.0

Table of Contents