matthewstorey.co.uk
In this section Binary Coded Decimal | Binary | Character Numeric Edited | Packed Decimal | Text | Zoned Decimal

Text

Codepages

All text in any language or on any platform is in a codepage.

A codepage is a map that links a character to one or more bytes.

ASCII codepages are use on most platforms, but in OS/390 and other platforms EBCDIC is used instead.

The basic PC codepage is 'Cp1252'
The basic mainframe codepage is 'Cp1047'

Limits:

COBOL only supports the codepage of the platform it is running on.

C and Java support multiple codepages and can use different ones at once.

Double Byte Character Sets (DBCS)

These are codepages where each character is a set of 2 byte values.

Limits:

Supported in COBOL for OS/390 and VM, C and Java.

Unicode

These are codepages where each character can be anything from 1 to 4 byte values.

Limits:

Supported from Enterprise COBOL for z/OS and OS/390 Version 3, C and Java.

Back to top