ADELIA |
|
|
|
|
(I) |
|
|
|
|
Section for use
INITIALIZATION, VERIFICATION, VALIDATION
Syntax
END_MANAGE_SFL
Description
This instruction marks the end of a subfile processing block.
It must be preceded by the "MANAGE_SFL n" instruction.
For each MANAGE_SFL there must be a corresponding END_MANAGE_SFL instruction, and vice versa.
It is not necessary to specify a subfile number.
Note: In the VERIFICATION section, this instruction performs an update for each reread record of the subfile.
Example
**********************
INITIALIZATION 02
**********************
MANAGE_SFL 2
* loading all order lines in subfile 2 and getting the item description
PRESENT ORDER_LINES
ZORDER_DATE = &DATE6_FORMAT('YMD';'MDY';ZORDER_DATE)
CHAIN ITEM
PRESENT ITEM
LAST_NUMBER = ZORDER_LINE_N
UPD_SFL
END_MANAGE_SFL
*
*********************
VERIFICATION 02
*********************
MANAGE_SFL 2
* verifying the item code for each line of subfile
CHAIN ITEM
IF ITEM DOES_NOT_EXIST
PREPARE_MSG 0029 ZITEM_CODE
ANOMALY
END
END_MANAGE_SFL
*
******************
VALIDATION 02
******************
MANAGE_SFL 2
* updating or creating order lines from the subfile
ZORDER_DATE = &DATE6_FORMAT('MDY';'YMD';ZORDER_DATE)
IF ZORDER_LINE_N = 0
LAST_NUMBER = LAST_NUMBER + 1
ZORDER_LINE_N = LAST_NUMBER
END
STORE ORDER_LINES
END_MANAGE_SFL
See also the list of 4GL instructions by topic