Use these field-level keywords to specify editing for the field you are defining when the field is referenced later during display or printer file creation. The EDTCDE and EDTWRD keywords do not affect the physical or logical file.
EDTCDE(edit-code [* | floating-currency-symbol])
EDTWRD('edit-word')
When defining an input-capable field in a display file, refer to the field you are defining by specifying the letter R in position 29 and the REF or REFFLD keyword. At display file creation, the operating system copies the EDTCDE or EDTWRD keyword and other field attributes from the field in the physical or logical file into the field in the display file. You can override the EDTCDE or EDTWRD keyword by specifying new editing keywords in the display or printer file. Specifying the DLTEDT keyword in the display or printer file deletes all editing for the field.
You cannot specify the EDTCDE or EDTWRD keyword on a floating-point field (F in position 35) or a hexadecimal field (H in position 35). Do not specify the EDTCDE or EDTWRD keyword on a date, time, or timestamp field (L, T, or Z in position 35).
The rules for specifying these keywords in a physical or logical file are the same as the rules for a display file.
The following example shows how to specify the EDTCDE and EDTWRD keywords for a physical file.
|...+....1....+....2....+....3....+....4....+....5....+....6....+....7....+....8 A R RECORD A A PRICE 5 2 EDTCDE(J) A A SALES 7 2 EDTCDE(K $) A A SALARY 8 2 EDTCDE(1 *) A A BALANCE 7 2 EDTWRD('$ 0. &CR') A A DATE 6 0 EDTCDE(Y) A
The fields PRICE, SALES, SALARY, and DATE have editing specified. No new editing needs to be specified when they are referred to by a display or printer file. This standardizes the editing of these fields for applications that refer to these fields.