SQL/MP Reference Manual
HP NonStop SQL/MP Reference Manual—523352-013
C-36
The LC_CTYPE Section of a Collation Definition
A class-element between two char symbols in the list can also be an ellipsis,
signifying the series of characters between the characters represented by the
char symbols within the character set.
Specify a class-name clause for each class-name you list on the charclass
clause.
toupper ( lower, upper ) [ ; ( lower, upper ) ] ...
specifies a set of char pairs that defines the relationship between lowercase and
uppercase characters.
char is defined in the discussion of the LC_COLLATE section. lower specifies a
lowercase char; upper specifies an uppercase char.
If neither char in a pair has appeared previously in the toupper clause, the first
character in the pair is handled as a lowercase character in the collation, and the
second character in the pair is handled as the corresponding uppercase character.
If you omit the toupper clause, SQL associates lowercase characters “a” to “z” with
uppercase characters “A” to “Z”.
You can define a character as the uppercase version of more than one lowercase
letter, or as the lowercase version of more than one uppercase letter. This is
useful, for example, if you define a collation for the French language, in which
accented lowercase letters often lose their accents if upshifted.
If the upper character in a pair appeared in a previous toupper pair, the latter pair
defines an upshift only. For example, in this toupper clause (which defines case
shifting for the French e-grave character):
toupper ( e, E);\
( \d232, E;)\
( \d232, \d200) # 232 is e-grave; 200 is E-grave
the toupper pair (\d232, E) specifies that e-grave upshifts to E but does not specify
how to downshift E; the toupper pair (\d232,\d200) specifies that E-grave
downshifts to e-grave, but does not specify how to upshift e-grave.
Similarly, if the lower character in a toupper pair appears in a previous pair, the
latter pair defines a downshift only.
At least one of the characters in each toupper pair must not have appeared in an
earlier pair.
END LC_CTYPE
ends an LC_CTYPE section.