XPED Quick Tip
In Xped a DB2 query is replaced by a PERFORM until and a call like this:
***** CLM_GEN =
***** :DCLCLIAM.CL-CL-ID AND
***** CL_STATUS = :DCLCLAIM.CL-STATUS
==> PERFORM SQL-INITIAL UNTIL SQL-INIT-DONE
CALL 'DSNHLI' USING SQL-PLIST2
First time execution of a DB2 query in a module will take the program flow inside the given SQL-INITIAL para:
GO TO SQL-INIT-END.
==> MOVE 1 TO SQL-INIT-FLAG.
CALL 'DSNHADDR' USING SQL-VPARMPTR OF SQL-PLIST2 SQL-PVAR-LIS
CALL 'DSNHADD2' USING SQL-PVAR-ADDRS1 IN
Two ways to avoid this are:
1. Put a breakpoint on call statement just after perform. In no circumstances you would require to go into the perform of SQL-INITIAL.
2. If in hurry you forget to do so and entered into such a call, then do “F Continue”
Put a break point there and do a PF12
CALL 'DSNHADDR' USING SQL-CODEPTR OF SQL-PLIST4 SQLCA.
Nobody will say you have successfully rectified your mistake but you have J.