Was this helpful?
EBCDIC
A built-in variable that, when set to a numeric value greater than 0, causes input lines to be converted from the various forms of EBCDIC to the standard ANSI code page. Since a file is always going to be either standard ANSI or one of the EBCDIC code pages, the EBCDIC built-in variable should be set in the BEGIN block to indicate that the script is expecting an EBCDIC file.
Example
# sets the code page to US EBCDIC.
BEGIN {
EBCDIC = 37;
The table below indicates the EBCDIC code page tables that can be translated and the numeric values for each of them:
Supported EBCDIC Codes and Their Numeric Values
 
Value
Type of EBCDIC Code Page
0
278
ANSI
 
37
US
273
Germany
277
Sweden
280
Italy
284
Spain
285
UK
297
France
437
MSDOS United States
500
Belgium
850
MSDOS Multilingual
860
MSDOS Portuguese
861
MSDOS Icelandic
863
MSDOS Canadian French
865
MSDOS Nordic
Last modified date: 01/25/2022