The following sequence of commands shows how to set breakpoints and control the execution of a process:
-* The debug session has already been established
DEBUG SET NEWHOLD=YES -* Ensure the procedure is stopped
-* on the first statement
DEBUG BREAKPOINT PROCEDURE=MYPROC STMT=1250000
-* Suspend the procedure if it
-* tries to execute statement 1250000
DEBUG BREAKPOINT PROCEDURE=MYPROC VERB=APPC
-* Suspend background procedure on
-* first APPC verb
DEBUG BREAKPOINT PROCEDURE=MYPROC VARS=WKTRANID DATA=CH22
-* Suspend the procedure when it sets
-* WKTRANID to the data that causes
-* the error. The procedure MYPROC is
-* started in window 2 and is
-* immediately suspended
DEBUG STEP NEXT=10 -* Execute the first 10 statements
-* Using the display commands the procedure is
-* verified as to the current state of its variables
DEBUG RESUME -* Let process continue
-* until first breakpoint
-* The procedure is suspended on the APPC verb. Using the
-* display commands, the procedure is verified as to the
-* current state of its variables. They are set correctly
DEBUG LIST BREAKPOINTS -* List all current breakpoints
DEBUG CLEAR BREAKPOINT=2 -* Clear the breakpoint on the
-* APPC verb
DEBUG RESUME -* Let the process continue until
-* next breakpoint
-* Process continues
| Copyright © 2011 CA. All rights reserved. | Tell Technical Publications how we can improve this information |