WRITE FILE Examples
Example 1:
|
|
|
|
|
Logical file: |
DATAFILE |
|
Method: |
Sequential (SEQ is a previously defined -1 or -2 numeric variable) |
|
Variables: |
VAR1, VAR2 and NAME |
|
List controls: |
*ZF zero-fills the numeric variable BALANCE |
|
Partial write: |
No semi-colon specified (writes End Of Record (EOR) mark) |
Example 2:
|
|
|
|
|
Logical file: |
MYFILE |
|
Method: |
Random (RECORD is previously defined 0 or greater numeric variable) |
|
Variables: |
FIELD1 and FIELD2 |
|
List controls: |
*+ enables space compression |
|
Partial write: |
Semi-colon specified for partial WRITE (no EOR) |
![]() |