DDS for printer files

OS/400 edit codes in printer files

The OS/400 edit codes are:
1 through 4
A through D
J through Q
W through Z

Note:
The iSeries server hardware operates with a preferred sign of F, which is equivalent to using edit code X. If the DATE or TIME keyword is specified with edit code X, the separator character is not displayed.

Asterisk fill or floating currency symbol in printer files:

You can optionally specify asterisk fill or floating currency symbol with edit codes 1 through 4, A through D, and J through Q.

When you specify asterisk fill, an asterisk (*) is written for each zero suppressed. A complete field of asterisks is printed for a zero-balance field.

When you specify floating-currency symbol, the symbol appears to the left of the first significant digit. It does not print on a zero balance when an edit code is used that suppresses the zero balance. The symbol you specify must match the system value for the currency symbol (QCURSYM). (The symbol must match when the file is created. It does not have to match when the file is used.)

Note:
If an edit code is changed after a file is created, the new edit code is not used unless the file is re-created. Instead, the editing specified at the time the file was created continues to be used.

The following table summarizes the functions provided by OS/400 edit codes.

Table 5. Summary Chart for OS/400 Edit Codes

Edit Codes Commas1 Printed Decimal Points1 Printed Signs Printed When Negative Number Blank Value of QDECFMT System Value I Value of QDECFMT System Value J Value of QDECFMT System Value Leading Zero Suppressed
1 Yes Yes No sign .00 or 0 ,00 or 0 0,00 or 0 Yes
2 Yes Yes No sign Blanks Blanks Blanks Yes
3
Yes No sign .00 or 0 ,00 or 0 0,00 or 0 Yes
4
Yes No sign Blanks Blanks Blanks Yes
A Yes Yes CR .00 or 0 ,00 or 0 0,00 or 0 Yes
B Yes Yes CR Blanks Blanks Blanks Yes
C
Yes CR .00 or 0 ,00 or 0 0,00 or 0 Yes
D
Yes CR Blanks Blanks Blanks Yes
J Yes Yes -(Minus) .00 or 0 ,00 or 0 0,00 or 0 Yes
K Yes Yes -(Minus) Blanks Blanks Blanks Yes
L
Yes -(Minus) .00 or 0 ,00 or 0 0,00 or 0 Yes
M
Yes -(Minus) Blanks Blanks Blanks Yes
N Yes Yes -(Minus) .00 or 0 ,00 or 0 0,00 or 0 Yes
O Yes Yes -(Minus) Blanks Blanks Blanks Yes
P
Yes -(Minus) .00 or 0 ,00 or 0 0,00 or 0 Yes
Q
Yes -(Minus) Blanks Blanks Blanks Yes
W2





Yes
Y3





Yes
Z4





Yes

Notes:

  1. The QDECFMT system value determines the decimal point character (period as used in the U.S.), the character used to separate groups of three digits (comma as used in the U.S.), and the type of zero suppression (depending on comma and period placement). For more information on the QDECFMT system value, see the System values topic under the Systems Management category of the iSeries Information Center.

  2. The W edit code suppresses the farthest left zero of a date field that is five digits long. It also suppresses the three farthest left zeros of a field that is six to eight digits long. The W edit code also inserts slashes (/) between the month, day, and year according to the following pattern:

    nn/nnn

    nnnn/nn

    nnnn/nnn

    nnnn/nn/nn

  3. The Y edit code suppresses the farthest left zero of a date field that is three to six digits long or eight digits long, and it suppresses the two farthest left zeros of a field that is seven positions long. The Y edit code also inserts slashes (/) between the month, day, and year according to the following pattern:

    nn/n

    nn/nn

    nn/nn/n

    nn/nn/nn

    nnn/nn/nn

    nn/nn/nnnn

    If the DATE keyword is specified with EDTCDE(Y), the separator character used is the job attribute, DATSEP at run time. If a separator character is not specified on the DATSEP job attribute, the system value, QDATSEP, is used (where slash (/) is the default value). If, at file creation time, DATFMT is JUL (Julian), the date is formatted as nnnnn. If EDTCDE(Y) is specified, the date is formatted as nn/nnn, where the slash (/) represents the job date separator.

  4. The Z edit code removes the sign (plus and minus) from a numeric field. The sign of the units column is changed to a hexadecimal F before the field is written.


[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]