It is possible to MOVE a field of format L to a field of format A.
But it is not possible to COMPRESS a field of format L into a field of format A.
This should be made possible, following the rules of a MOVE:
TRUE as x'E7'
FALSE as x'40'
Example for MOVE:
DEFINE DATA LOCAL
01 #TRUE (L)
01 #FALSE (L)
01 A-TRUE (A1)
01 A-FALSE(A1)
END-DEFINE
*
#TRUE := TRUE
#FALSE := FALSE
MOVE #TRUE TO A-TRUE
MOVE #FALSE TO A-FALSE
WRITE
'#TRUE :' #TRUE #TRUE (EM=HH) 'A-TRUE :' A-TRUE A-TRUE(EM=HH) /
'#FALSE:' #FALSE #FALSE (EM=HH) 'A-FALSE:' A-FALSE A-FALSE(EM=HH)
END
Output:
#TRUE : X 01 A-TRUE : X E7
#FALSE: 00 A-FALSE: 40
Created on Brainstorm | 12/05/2013 08:27 |
Brainstorm ID | 523 |