For simple character sets in MySQL 4.1, sorting rules are
specified in the
configuration file using MYSET
.xml<map>
array
elements within <collation>
elements.
(For MySQL 4.0 or older, the rules are given by the
sort_order
array in
.) If
the sorting rules for your language are too complex to be
handled with simple arrays, you need to define string collating
functions in the
MYSET
.confctype-
source file in the MYSET
.cstrings
directory.
The existing character sets provide the best documentation and
examples to show how these functions are implemented. Look at
the ctype-*.c
files in the
strings
directory, such as the files for
the big5
, czech
,
gbk
, sjis
, and
tis160
character sets. For MySQL 4.1, take a
look at the MY_COLLATION_HANDLER
structures
to see how they are used, and see the
CHARSET_INFO.txt
file in the
strings
directory for additional
information. For MySQL 4.0 or older, look at the
CHARSET_INFO
structures.
User Comments
Add your own comment.