A coded character set is a set of rules that establishes a character set and the one-to-one relationship between the characters of the set and their code values. The same character set can exist with different encodings. For example, the LATIN1-based character set can be encoded in an International Organization for Standardization (ISO) format or an EBCDIC format. Coded character sets are defined in the MultiLingual System Administration, Operations, and Programming Guide. A coded character set name or number is given to each unique coded character set definition.
A coded character set name or number can also be used to set the INTMODE or EXTMODE file attribute values for a file. For more information on how to use the INTMODE and EXTMODE file attributes, see the File Attributes Programming Reference Manual.
A ccsversion is a collection of information necessary to apply a coded character set in a given country, language, or line of business. This information includes the processing requirements such as data classes, lowercase-to-uppercase mapping, ordering of characters, and the presentation set and escapement rules necessary for output. A ccsversion name and number is given to each unique group of information. A ccsversion name or number can also be used to set the CCSVERSION file attribute for a file. For more information, refer to the File Attributes Programming Reference Manual.
Each enterprise server includes a data file, SYSTEM/CCSFILE, containing all coded character sets and ccsversions that are supported on the system. You cannot choose a coded character set directly, but by choosing a ccsversion, you implicitly designate the default coded character set for your system.
Data can be entered and manipulated in only one coded character set and ccsversion at a time. Although there are many ccsversions, which can be accessed, there is only one ccsversion active for the entire system at one time. This is called the system default ccsversion. See Using the Ccsversion, Language, and Convention Default Settings and Understanding the Hierarchy for Default Settings.
Several ways exist to determine which coded character sets and ccsversions are available on your system.
-
Look in the MultiLingual System Administration, Operations, and Programming Guide. Your system might have a subset of the ones defined in that guide.
-
Use the MARC menus and screens or the system command SYSTEMOPTIONS. Refer to the MultiLingual System Administration, Operations, and Programming Guide or the System Commands Reference.
-
Call the CCSVSN_NAMES_NUMS procedure.
You might want to refer to the MultiLingual System Administration, Operations, and Programming Guide for a complete understanding of ccsversions and the relationship of a coded character set and a ccsversion.
All coded character set and ccsversion information on your system can be accessed by calling CENTRALSUPPORT library procedures. To call these CENTRALSUPPORT library procedures, an ALGOL program should first include a file provided by Unisys that declares all the library procedures. This file is called *SYMBOL/INTL/ALGOL/PROPERTIES. The procedures can then be used in the program. The file also contains DEFINES for some input parameters and DEFINES for the results returned from the procedures. The method for including *SYMBOL/INTL/ALGOL/PROPERTIES in your ALGOL program is shown in each of the CENTRALSUPPORT library procedures detailed later in this section. If the file is not included, any library procedure that is used must be declared individually in the program.
Many of the procedures require the specification of a coded character set or ccsversion as an input parameter. A program can choose a specific coded character set or ccsversion by calling the procedures using the name or number of the coded character set or the ccsversion as an input parameter. For example, by calling the VSNORDERING_INFO procedure with the ccsversion name ASeriesNative, then calling the VSNORDERING_INFO procedure again with the ccsversion name SWISS your program could access data in the ASeriesNative ccsversion and then access data in the SWISS ccsversion. A program can also use the system default setting by using predefined values as input parameters. See “Input Parameters” later in this section for specific information about those parameters.
Mapping Tables
A mapping table is used to map one group of characters to another group of characters or another representation of the original characters. Many CENTRALSUPPORT library procedures store coded character set and ccsversion information in ALGOL translate tables as a way of defining, processing, and mapping data. For example, a translate table can exist to translate lowercase characters to uppercase characters.
The internationalization procedures provide you with access to translate tables that apply to data specified in coded character sets or specified ccsversions. These translate tables are as follows:
-
Mapping data from one coded character set to another coded character set
-
Mapping data from lowercase to uppercase characters
-
Mapping data from uppercase to lowercase characters
-
Mapping data from alternative numeric digits defined in a ccsversion to numeric digits defined in U.S. EBCDIC
-
Mapping data from numeric digits in U.S. EBCDIC to alternative numeric digits defined in a ccsversion
-
Mapping characters to their escapement values
You must use procedures from the CENTRALSUPPORT library to access these translate tables or to process data using these tables. For example, you use the CCSTOCCS_TRANS_TEXT procedure to translate data from one coded character set to another coded character set. You use the VSNTRANS_TEXT procedure to map lowercase data to uppercase.
See the MultiLingual System Administration, Operations, and Programming Guide for definitions of mapping tables for each coded character set and ccsversion.
Data Classes
A data class is a group of characters sharing common attributes such as alphabetic, upon which membership tests can be made. A truth set is a method of storing the declared set of characters upon which membership tests can be made. Many CENTRALSUPPORT library procedures store ccsversion information in ALGOL truth set tables as a way to define ccsversion data classes.
The internationalization features provide you with access to truth sets that apply to a ccsversion. These truth sets are as follows:
-
Ccsversion alphabetic
-
Ccsversion numeric
-
Ccsversion graphics
-
Ccsversion spaces
-
Ccsversion lowercase
-
Ccsversion uppercase
The alphabetic truth set contains those characters that are considered to be alphabetic for a specified ccsversion. The numeric truth set contains those characters that are considered to be numbers for a specified ccsversion, and so on.
You can use procedures from the CENTRALSUPPORT library to access these truth sets or to process data using these truth sets. For example, if a program manipulates an employee identification number such as 555962364, it might then need to verify that the text is all numeric. The program can call the VSNINSPECT_TEXT CENTRALSUPPORT library procedure to compare the text to the numeric truth set. This procedure returns the information that the text is or is not all numeric.
Refer to the MultiLingual System Administration, Operations, and Programming Guide for definitions of ccsversions and data classes.
Text Comparisons
A text comparison can be required for sorting text, or for comparing relationships between two pieces of text.
The traditional method for handling text comparisons is based on a strict binary comparison of the character values. The binary method of comparison is not meaningful when used for sorting text if the binary ordering of the coded characters does not match the ordering sequence of the alphabet of the language. This situation is the case for most coded character sets.
Because the binary method is not sufficient for all usage requirements, Unisys supports the definitions of two other levels of ordering.
The first level is called Ordering. Each character gets an ordering sequence value (OSV). An OSV is an integer from 0 through 255, assigned to each code position in a character set. The OSV signifies a relative ordering value of a character. An OSV of 0 indicates that the character comes before a character with an OSV of 1. More than one character can be assigned the same OSV.
The second level is called Collating. Each character gets an OSV and a priority sequence value (PSV). A PSV is an integer from 1 to 15 that is assigned to each code position in a character set. The PSV is a relative priority value within each OSV. Each character with a unique OSV has a PSV of 1; however, if 2 characters have the same OSV, they will have different PSVs for additional differentiation.
In comparing two strings of data, a comparison which uses only 1 level, the Ordering level, is called an equivalent comparison. A comparison which utilizes both levels, Ordering and Collating, is called a logical comparison.
You can use the following three types of text comparisons by calling the procedures of the CENTRALSUPPORT library:
|
Order Type |
Explanation |
|
Binary |
A comparison based on the hexadecimal code values of the characters |
|
Equivalent |
A comparison based on the ordering sequence values (OSVs) of the characters |
|
Logical |
A comparison based on the OSVs plus the priority sequence values (PSVs) of the characters |
In addition to the three types of ordering, Unisys also supports the following two types of character substitution:
|
Substitution |
Explanation |
|
Many to One |
A predetermined string of up to three characters can be ordered as if it were one character, assigning it a single OSV and PSV pair. Even if a character is part of a predetermined string of characters that are ordered as a single value, the character still has an OSV and a PSV pair assigned to it to allow for cases in which the character appears in other strings or individually. For example, in Spanish, the letter pair ch is ordered as if it were a single letter, different from either c or h, and ordering between c and d. |
|
One to Many |
A single character can generate a string of two or three OSV and PSV pairs. For example, the β (the German sharp S) character is ordered as though it were ss. |
For a description of how the characters in each ccsversion are ordered and how text comparisons work, see the MultiLingual System Administration, Operations, and Programming Guide.

