Understanding the ASCII-EBCDIC and EBCDIC-ASCII translation tables

NoteThe translation tables shown here are used in date conversion only if Unicode support is disabled and USEIBMUNICODE=N.

The four pairs of default, or “base,” tables are:

Each pair includes a table for ASCII-to-EBCDIC translation, and one for EBCDIC-to-ASCII translation.

NoteAs supplied, all ASCII character sets translate to and from EBCDIC code page 500 (iso_1) on the mainframe by default.

For the ASCII-to-EBCDIC tables, find the leftmost hexadecimal ASCII digit to the left of the table as a digit followed by an underscore. Find the rightmost hexadecimal ASCII digit on top of the table as a digit preceded by an underscore.

Here is an example from the default table in the section “ASCII_8, ASCII-to-EBCDIC translation table”.

Figure B-1: Example from the ASCII_8, ASCII-to-EBCDIC translation table

To locate ASCII x'26', find row 2_ to the left of the table, and proceed along that row to the column headed by _6. At the intersection is x'50'. Therefore, ASCII x'26' is translated to EBCDIC x'50'.

For the EBCDIC-to-ASCII tables, find the leftmost hexadecimal EBCDIC digit to the left of the table as a digit followed by an underscore. Find the rightmost hexadecimal EBCDIC digit on top of the table as a digit preceded by an underscore.

Here is an example from the default table in the section “ASCII_8, ASCII-to-EBCDIC translation table”.

Figure B-2: Example from the ASCII_8, EBCDIC-to-ASCII translation table

To locate EBCDIC x'26', find row 2_on the left side of the table; then proceed along that row to the column headed by _6. At the intersection is x'17'. Therefore, EBCDIC x'26' is translated to ASCII x'17'.

WARNING! If you create a new table from a default table, give the new table a unique name and coordinate with the appropriate person at the Sybase client site. The client can use the name to issue logins to TRS.