1 | Receiver variable | Output | Char(*) |
2 | Receiver variable length | Input | Binary(4) |
3 | Source variable | Input | * |
4 | Source variable class | Input | Char(10) |
5 | Source variable precision | Input | Binary(4) |
6 | Edit mask | Input | Char(*) |
7 | Edit mask length | Input | Binary(4) |
8 | Zero balance fill character | Input | Char(1) |
9 | Error code | I/O | Char(*) |
The Edit (QECEDT) API uses an edit mask to transform a numeric from its internal format to a character form suitable for displaying.
None.
Receives the edited output. The length of this area must be passed in the receiver variable length parameter.
The length of the referenced area by the receiver variable parameter. This value must be greater than 0.
This value was returned in the receiver variable length parameter on the previous call to the Convert Edit Code (QECCVTEC) API or Convert Edit Word (QECCVTEW) API; otherwise, CPF27AF is returned.
The numeric value that is converted. The type is defined by the source variable class parameter and the length is specified in the source variable precision parameter.
The type of numeric variable passed in the source variable parameter.
The types are:
*BINARY
*PACKED
*ZONED
The precision of the numeric variable specified in the source variable parameter.
The value passed must be from 1 through 31.
Variable Class |
Precision |
---|---|
Packed | The precision for which the variable was declared. For example, PACKED(8,4) has precision 8. |
Zoned | The precision for which the variable was declared. For example, ZONED(8,4) has precision 8. |
Binary(2) | 5 |
Binary(4) | 10 |
Note: Some high-level languages limit the maximum precision of packed and zoned numeric variables.
The edit mask used for this edit operation. This is the value returned in the edit mask parameter on the call to the QECCVTEC API or QECCVTEW API.
The length of the edit mask. The value passed must be from 1 through 256. This is the value returned in the edit mask length parameter on the call to the QECCVTEC API or QECCVTEW API.
Indicates how to perform the edit operation so that zero balance suppression is done correctly for those edit codes that have zero balance suppression.
If the QECCVTEC API is used to create the edit mask, this should be the value returned in the zero balance fill character parameter; otherwise, unpredictable results may occur.
If the QECCVTEW API is used to create the edit mask, X'00' should be specified for this parameter; otherwise, unpredictable results may occur.
The structure in which to return error information. For the format of the structure, see Error Code Parameter.
Message ID | Error Message Text |
---|---|
CPF27AB E | Source variable class not valid. |
CPF27AF E | Edit mask not valid. |
CPF27B4 E | Source variable precision not valid. |
CPF27B7 E | Receiver variable length not valid. |
CPF27B8 E | Edit mask length not valid. |
CPF3C90 E | Literal value cannot be changed. |
CPF3CF1 E | Error code parameter not valid. |
Top | Edit Function APIs | APIs by category |