How to load values from AUGDT to an attribute conditionally
There’s need to load values from AUGDT to FACDOCNO__ZCLEAR_DT.
(ZCLEAR_DT is a copy of 0clear_date, FACDOCNO is a characteristic loaded with document numbers (BELNR), ZCLEAR_DT is an attribute of FACDOCNO).
Is there a way to use any formula for it assuming that:
- loading should function only if in a given record there is a value “X” against SAKNR
- an empty string mustn’t overwrite value that has already has been loaded).
BELNR SAKNR AUGDT
1 Y aaa should not be loaded
1 X bbb should be loaded
1 X empty should not be loaded
1 X ccc should be loaded
Now we have cc value in FACDOCNO_ZCLEAR_DT
My idea is:
IF( NOT IS_INITIAL( AUGDT ) AND SAKNR = 'X' ), AUGDT, SKIP_RECORD( ) )
But I’m not sure if IS_INITIAL should be used here. Does this check if loaded value is not empty ???
And I’m not sure if SKIP_RECORD will work OK. What exactly in this case that "skip" mean ?? I'm afraid of skipping record in facdocno after encountering the first empty value in the source table.
There are some post's on SCN on that topic but I found nothing to help me so far.