hi all.
MY PROGRAM IS ARITHMETIC ADDITION OPERATIONS, WHEN SPACES ARE ALLOWED IN FIELDS.
IDENTIFICATION DIVISION.
PROGRAM-ID. ARTH.
DATA DIVISION.
WORKING-STORAGE SECTION.
COPY DFHBMSCA.
COPY DFHAID.
COPY ARTSET.
77 A PIC X(2) VALUE 'AB'.
01 I PIC 9 VALUE 3.
01 J PIC 9 VALUE 3.
01 A1 PIC 999.
01 A2 PIC 999.
01 X PIC X(1).
88 NOT-FOUND VALUE 'A'.
PROCEDURE DIVISION.
EXEC CICS
HANDLE CONDITION
MAPFAIL(PARA)
END-EXEC.
IF EIBCALEN = 0
MOVE LOW-VALUES TO ARTMAPO
PERFORM SEND-MAP
ELSE
EVALUATE EIBAID
WHEN DFHENTER
PERFORM RECEIVE-MAP
WHEN DFHPF1
MOVE DFHBMFSE TO NUM1I
NUM2I
PERFORM RECEIVE-MAP
PERFORM ADD-PARA
PERFORM SEND-MAP
WHEN DFHPF3
EXEC CICS
RETURN
END-EXEC
WHEN OTHER
PERFORM RECEIVE-MAP
MOVE LOW-VALUES TO ARTMAPO
MOVE 'ENTER APPRORIATE KEY' TO MSGO
PERFORM SEND-MAP
END-EVALUATE
END-IF.
RECEIVE-MAP.
EXEC CICS
RECEIVE MAP('ARTMAP')
MAPSET('ARTSET')
INTO(ARTMAPI)
END-EXEC.
SEND-MAP.
EXEC CICS
SEND MAP('ARTMAP')
MAPSET('ARTSET')
FROM(ARTMAPO)
END-EXEC.
EXEC CICS
RETURN TRANSID('TID2')
COMMAREA(A)
END-EXEC.
ADD-PARA.
PERFORM UNTIL NOT-FOUND
IF NUM1I(I:1) IS NUMERIC
IF NUM2I(J:1) IS NUMERIC
MOVE NUM1I(1:I) TO A1
MOVE NUM2I(1:J) TO A2
COMPUTE RESULTO = A1 + A2
SET NOT-FOUND TO TRUE
ELSE
SUBTRACT 1 FROM J
END-IF
ELSE
SUBTRACT 1 FROM I
END-IF
END-PERFORM.
PARA.
MOVE 'ENTER APP VALUE' TO MSGO.
PERFORM SEND-MAP.
MY MAP HAVE THREE UNPROTECTED FIELDS
NUM1 WITH 9(3), NUM2 WITH 9(3) AND RESULT WITH 9(3).
WHEN I TRIGGER THE TRANSACTION FOR THE FIRST TIME RESULT IS COMING, ( EX- WHEN I GIVE 12 IN NUM1, AND 12 IN NUM2 I'M GETTING RESULT 024), AND FIRST THE SECOND TIME WHEN I GIVE OTHER OR SAME VALUES IM NOT GETTING ANY RESULT.
WHAT IS THE PROBLEM WITH MY PROGRAM.
PLZ CLARIFY.