EXTRACT

The EXTRACT macro obtains information from the task control block (TCB). TCB information may change when the task terminates and the job step restarts. If the information is needed after restart, the EXTRACT macro instruction should be reissued after the checkpoint is taken, as shown in Figure 1.

Figure 1. Obtaining Updated TCB Information after Restart
            .
            .
            .
            EXTRACT    ANSADDR,FIELDS=(ALL)   Obtain TCB
*                                             information
            .
            .
            .
            CHKPT      CHKPTDCB               Establish
*                                             checkpoint
            CH         15,=H'4'               Is restart in
*                                             progress
            BNE        NRESTART               No, branch to
*                                             NRESTART
            EXTRACT    ANSADDR,FIELDS=(ALL)   Yes, obtain new
*                                             information
NRESTART
            .
            .
            .