Sign in

docs RPG Reference

Edit Code Summary

Edit Code Summary

Table 1. Edit Codes

Edit Code DescriptionNo SignCr Sign-Sign(R)-Sign(L)
Commas and zero balances1AJN
Commas2BKO
Zero balances3CLP
No commas or zero balances4DMQ
User-defined edit codes5 - 9
Hexadecimal F signX1
Date editY2
Suppress leading zerosZ3
Note: 1. The X edit code ensures a hexadecimal F sign for positive values. Because the system does this for you, normally you do not have to specify this code. 2. The Y edit code suppresses the leftmost zeros of date fields, up to but not including the digit preceding the first separator. The Y edit code also inserts slashes (/) between the month, day, and year according to the following pattern (with zero suppression): rpgle nn/n nn/nn nn/nn/n nn/nn/nn nnn/nn/nn nn/nn/nnnn nnn/nn/nnnn nnnn/nn/nn nnnnn/nn/nn 3. The Z edit code removes the sign (plus or minus) from a numeric field and suppresses leading zeros.