Previous Topic

Next Topic

Book Contents

Book Index

Examples for DO SYSOUT

DO SYSOUT Example 1

If a job finishes executing OK, delete (purge) the sysout (DO SYSOUT OP D). If the job finishes executing with condition code 0050-0059 in step STEP02, set the end status of the job to OK and release the sysout for printing. If the job abends, move the sysout to class D.

Figure 215 DO SYSOUT Parameter – Example 1

JOB: SACALC01 LIB CTM.PROD.SCHEDULE                       TABLE: SALARY

COMMAND ===>                                            SCROLL===> CRSR

+---------------------------------------------------------------------+

  OUT                                                                 

  AUTO-ARCHIVE Y          SYSDB    Y      MAXDAYS      MAXRUNS         

  RETENTION:  # OF DAYS TO KEEP 030  # OF GENERATIONS TO KEEP          

  SYSOUT OP   (C,D,F,N,R)                                         FROM

  MAXRERUN     RERUNMEM                             INTERVAL   FROM    

  STEP RANGE         FR (PGM.PROC)          .          TO        .     

  ON PGMST ANYSTEP  PROCST          CODES OK                        A/O

    DO SYSOUT    OPT D PRM                                          FRM

  ON PGMST STEP02   PROCST          CODES C005*                    A/O

    DO OK                                                              

    DO SYSOUT    OPT R PRM                                         FRM

    DO                                                                 

  ON PGMST ANYSTEP  PROCST          CODES U**** S****               A/O

    DO SYSOUT    OPT C PRM D                                        FRM

    DO                                                                 

  ON PGMST          PROCST          CODES                           A/O

    DO                                                                 

  ON SYSOUT                                      FROM 001 TO 132    A/O  

    DO                                                                

  ON VAR                                                              

    DO                                                                

  SHOUT WHEN           TIME       +     DAYS     TO             URGN   

    MS                                                                 

======= >>>>>>>>>>>>>>> END OF SCHEDULING PARAMETERS <<<<<<<<<<<< =====

COMMANDS: EDIT, DOC, PLAN, JOBSTAT                            11.17.00

DO SYSOUT Example 2 – Use of the Sysout Archiving Facility

The MSGCLASS of the job is X (a held class). Reports are produced in class D. The desired actions are:

JOB: GPLUPDT1 LIB CTM.PROD.SCHEDULE                      TABLE: PRODGPL

COMMAND ===>                                            SCROLL===> CRSR

+---------------------------------------------------------------------+

  =====================================================================

  OUT                                                                  

  RETENTION:  # OF DAYS TO KEEP 030  # OF GENERATIONS TO KEEP          

  AUTO-ARCHIVE Y          SYSDB    Y      MAXDAYS      MAXRUNS         

  SYSOUT OP   (C,D,F,N,R)                                          FROM

  MAXRERUN     RERUNMEM                            INTERVAL    FROM    

  STEP RANGE         FR (PGM.PROC)          .          TO        .     

  ON PGMST ANYSTEP  PROCST          CODES *****                    A/O

    DO SYSOUT   OPT F PRM GPL.%%JOBNAME.D%%ODATE.N%%JOBID.T%%TIME FRM X

    DO                                                                 

  ON PGMST ANYSTEP  PROCST          CODES OK                        A/O

    DO SYSOUT    OPT D PRM                                        FRM X

    DO SYSOUT    OPT R PRM                                        FRM D

    DO                                                                 

  ON PGMST ANYSTEP  PROCST          CODES NOTOK                    A/O

    DO SYSOUT    OPT D PRM                                        FRM D

    DO                                                                 

  ON PGMST          PROCST          CODES                           A/O

    DO                                                                 

  ON SYSOUT                                      FROM 001 TO 132    A/O  

    DO                                                                

  ON VAR                                                              

    DO                                                                

  SHOUT WHEN           TIME       +     DAYS     TO             URGN   

COMMANDS: EDIT, DOC, PLAN, JOBSTAT                            11.17.00

Notice the use of the AutoEdit symbols in the name of the file to be archived. The symbol %%JOBNAME, or %%$MEMNAME if the job name is not known, is replaced with the job name, %%ODATE by the original scheduling date, and so on, producing a file name such as "PRD.PADD0040.D010306.N01342.T170843."

The file can be viewed by using ISPF Browse. A list of the outputs of the job can be produced using ISPF option 3.4. For example, retrieval by the prefix "PRD.PAPD0040.D0103" lists all the names of the sysouts of the job in the month of March 2001. It is possible to browse, edit, and print the desired sysout.

Note: The File operation (SYSOUT archival) is intended for small sysouts (such as JCL, sort messages) and not for large volume reports. When the Control-M monitor is performing file operations, it does not analyze the results of other jobs. Therefore, if large files are archived, production throughput may suffer.

Parent Topic

DO SYSOUT: Post-Processing Parameter