COBOL argument values

In COBOL, you can replace the argument values of the CICSPlex® SM API with different data types. The data type that you can use depends on the type of argument value.

data-value
Can be replaced by any COBOL data name of the correct data type for the argument, or by a constant that can be converted to the correct type for the argument. The table that follows indicates how to define the correct data type:
Data type COBOL definition
Halfword binary PIC S9(4) USAGE BINARY
Fullword binary PIC S9(8) USAGE BINARY
Doubleword binary PIC S9(18) COMP
Pointer USAGE IS POINTER
Character string PIC X(n) where n is the number of bytes
UTF-8 character string PIC X(n) where n is the number of bytes
Packed decimal PIC S9(n) COMP-3 where n is the number of decimal digits
data-value includes data-ref as a subset.
data-ref
Can be replaced by any COBOL data name of the correct data type for the argument. The table that follows indicates how to define the correct data type:
Data type COBOL definition
Halfword binary PIC S9(4) USAGE BINARY
Fullword binary PIC S9(8) USAGE BINARY
Doubleword binary PIC S9(18) COMP
Pointer USAGE IS POINTER
Character string PIC X(n) where n is the number of bytes
UTF-8 character string PIC X(n) where n is the number of bytes
Packed decimal PIC S9(n) COMP-3 where n is the number of decimal digits
Where the data type is unspecified, data-ref can refer to an elementary or group item.
data-area
Can be replaced by any COBOL data name with a data type of halfword binary (PIC S9(4) COMP), fullword binary (PIC S9(8) COMP), or character string (PIC X(n)).
ptr-ref
Can be replaced by a pointer variable or an ADDRESS special register.
cpsm-token
Can be replaced by any COBOL data name with a data type of fullword binary (PIC S9(8) COMP).


eyup2e9.html | Timestamp icon Last updated: Monday, 5 June 2017