~vlad-lesin/percona-server/mysql-5.0.33-original

« back to all changes in this revision

Viewing changes to sql/share/charsets/README

  • Committer: Vlad Lesin
  • Date: 2012-07-31 09:21:34 UTC
  • Revision ID: vladislav.lesin@percona.com-20120731092134-zfodx022b7992wsi
VirginĀ 5.0.33

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
This directory holds configuration files which allow MySQL to work with
 
2
different character sets.  It contains:
 
3
 
 
4
*.conf
 
5
    Each conf file contains four tables which describe character types,
 
6
    lower- and upper-case equivalencies and sorting orders for the
 
7
    character values in the set.
 
8
 
 
9
Index
 
10
    The Index file lists all of the available charset configurations.
 
11
 
 
12
    Each charset is paired with a number.  The number is stored
 
13
    IN THE DATABASE TABLE FILES and must not be changed.  Always
 
14
    add new character sets to the end of the list, so that the
 
15
    numbers of the other character sets will not be changed.
 
16
 
 
17
Compiled in or configuration file?
 
18
    When should a character set be compiled in to MySQL's string library
 
19
    (libmystrings), and when should it be placed in a configuration
 
20
    file?
 
21
 
 
22
    If the character set requires the strcoll functions or is a
 
23
    multi-byte character set, it MUST be compiled in to the string
 
24
    library.  If it does not require these functions, it should be
 
25
    placed in a configuration file.
 
26
 
 
27
    If the character set uses any one of the strcoll functions, it
 
28
    must define all of them.  Likewise, if the set uses one of the
 
29
    multi-byte functions, it must define them all.  See the manual for
 
30
    more information on how to add a complex character set to MySQL.
 
31
 
 
32
Syntax of configuration files
 
33
    The syntax is very simple.  Comments start with a '#' character and
 
34
    proceed to the end of the line.  Words are separated by arbitrary
 
35
    amounts of whitespace.
 
36
 
 
37
    For the character set configuration files, every word must be a
 
38
    number in hexadecimal format.  The ctype array takes up the first
 
39
    257 words; the to_lower, to_upper and sort_order arrays take up 256
 
40
    words each after that.