What is picture clause in mainframe?
The Picture clause is used to specify the type and size of an elementary data item. It consists of the word PIC or PICTURE followed by the actual picture clause, where the type and size are specified. The type is specified using a specific character selected from the table below.
What does P PICTURE character indicate in COBOL?
P symbol. The symbol P specifies a scaling position and implies an assumed decimal point (to the left of the Ps if the Ps are leftmost PICTURE characters; to the right of the Ps if the Ps are rightmost PICTURE characters).
What is DBCS in mainframe?
DBCS support translates Single-byte Character Set (SBCS) and DBCS data in the form that is supported on the requested platform. DBCS character representation differs between operating systems. Specifically, a mainframe represents data in 8-bit EBCDIC code and a PC represents data in 7-bit ASCII code.
Can there be more than one comma in picture clause?
Note that the functions of comma and period are exchanged if the DECIMAL-POINT IS COMMA clause is stated in the program’s SPECIAL-NAMES paragraph. Represent editing sign control symbols. These can occur more than once. Each counts in the size of an item.
What is CR and DB in COBOL?
CR and DB – When CR or DB is used as a symbol, it must define as the rightmost two-character positions in the character-string. They only appear in the rightmost position. Both characters (CR or DB) are printed only if the item is negative. Otherwise two spaces are printed.
What are the different picture clauses?
Picture Clause. Data type can be numeric, alphabetic, or alphanumeric. Numeric type consists of only digits 0 to 9. Alphabetic type consists of letters A to Z and spaces.
What is a two byte character?
A double-byte character set (DBCS) is a character encoding in which either all characters (including control characters) are encoded in two bytes, or merely every graphic character not representable by an accompanying single-byte character set (SBCS) is encoded in two bytes (Han characters would generally comprise most …
What is the meaning of double byte characters?
Double-byte characters. Each double-byte character contains 2 bytes, each of which must be in the range X’41’ to X’FE’. The first byte of a double-byte character is known as the ward byte. For example, the ward byte for the double-byte representation of EBCDIC characters is X’42’.
How many bytes is S9 9 comp?
4 bytes
COMPUTATIONAL-5 or COMP-5 (native binary)
Picture | Storage representation |
---|---|
S9(1) through S9(4) | Binary halfword (2 bytes) |
S9(5) through S9(9) | Binary fullword (4 bytes) |
S9(10) through S9(18) | Binary doubleword (8 bytes) |
9(1) through 9(4) | Binary halfword (2 bytes) |