PRINT: print information about records logged on an MVS log

Use the PRINT command to print the contents of MVS™ logs, and to find information about records logged on them.

Format

Read syntax diagramSkip visual syntax diagram
>>-PRINT--+-----------------------+----------------------------->
          | .-ALL-.               |   
          '-+-----+--CICSVR--CICS-'   

>--+-NAME--(--log stream name--)-+------------------------------>
   '-COPY------------------------'   

>--+---------------------------+-------------------------------->
   '-STARTIME--(--timestamp--)-'   

>--+---------------------------+-------------------------------><
   '-STOPTIME--(--timestamp--)-'   

Keywords

ALL
This is the default.
This specifies that the utility must print information about all records found on the MVS log. This keyword is mutually exclusive with the CICS® and CICSVR keywords.
CICSVR
This specifies that the utility must print only information about records logged by CICS VR
CICS
This specifies that the utility must print only information about records logged by CICS, including forward recovery and autojournalled records. Printing of records from the CICS system log, such as CICS undo records, is not supported by this utility.
NAME(log stream name)
This keyword identifies the data set name of the MVS log stream used by the utility.
log stream name
Specifies the name of the MVS log stream. The name is 1 to 26 characters long.
The NAME keyword is optional. If NAME is omitted from the command, the COPY keyword must be specified.
COPY
This indicates that the logs specified by the DWWLOG ddname are QSAM copies of MVS log streams. The COPY keyword is optional. If COPY is omitted from the command, the NAME keyword must be specified.
STARTTIME(timestamp)
If present, this keyword specifies the time that the utility uses as a start time when reading blocks from the MVS log. If STARTTIME is missing, the utility starts with the first block.
STOPTIME(timestamp)
If present, this keyword specifies the time that the utility uses to stop reading blocks from the MVS log. If omitted, the utility runtime is used as the stop time.
timestamp
Must be in the format yyyy/ddd/hh/mm/ss, where:
yyyy
Is the four digit year number (2001)
ddd
Is the day of the year (001–366)
hh
Is the hour of the day (00–23)
mm
Is the number of minutes (00–59)
ss
Is the number of seconds (00–59)
You can separate these values with a slash (/), period (.), or colon (:). You can also omit the separator character. For example:
STARTTIME(2001.159/:23:00)

You cannot substitute commas, blanks, and so on, for the time values, but you can omit values from the right. For example, if you specify STARTTIME(2001.159), CICS VR assumes that the time segment is 00:00:00.

EXCLUDE(specific log records)
Use the EXCLUDE command to eliminate specific log records from the Journal Print utility.
Format
EXCLUDE FILEID ( id1,id2,...) TERMID ( id1,id2,...) TRANSID ( id1,id2,...)
Keywords
FILEID(id1,id2,...)
Specifies that the utility must ignore any log records with these file IDs when printing records. If more than one keyword is specified, for example; EXCLUDE FILEID(DD1),TERMID(TST1), the log record must match both IDs specified for it to be excluded.
Id1,id2,...
Specifies the FILEID defined to CICS. id1, id2, for example, can be 1-8 characters. Up to 99 IDs can be specified for one FILEID. If more than one ID is specified on the FILEID keyword, a log record only needs to match one of the specified file IDs to be excluded
TERMID(id1,id2,...)
Specifies that the utility must ignore any log records with these terminal IDs when printing records. If more than one keyword is specified, for example, EXCLUDE FILEID(DD1),TERMID(TST1), the log record must match both IDs specified for it to be excluded
Id1,id2,...
Specifies the TERMINALID defined to CICS. id1, id2, for example, can be 1 to 4 characters. Up to 99 IDs can be specified for one TERMID. If more than one ID is specified on the TERMID keyword, a log record needs to match only one of the specified terminal IDs to be excluded.
TRANSID(id1,id2,...)
Specifies that the utility must ignore any log records with these transaction IDs when printing records. If more than one keyword is specified, for example, EXCLUDE TRANSID(APQ1),TERMID(TST1), the log record must match both IDs specified for it to be excluded.
Id1,id2,...
Specifies the TRANSACTIONID defined to CICS. id1, id2, for example, can be 1 to 4 characters. Up to 99 IDs can be specified for one TRANSID. If more than one ID is specified on the TRANSID keyword, a log record only needs to match one of the specified TRANSACTIONIDs to be excluded.
INCLUDE(specific log records)
Use the INCLUDE command to selectively include specific log records from the Journal Print utility.
Format
INCLUDE FILEID ( id1,id2,...) TERMID ( id1,id2,...) TRANSID ( id1,id2,...)
Keywords
FILEID(id1,id2,...)
Specifies that the Journal Print utility use log records only with these file IDs. If more than one keyword is specified, for example; INCLUDE FILEID(DD1),TERMID(TST1), the log record must match both IDs specified for it to be included.
Id1,id2,...
Specifies theFILEID defined to CICS. For example; id1, id2,can be 1 to 8 characters. Up to 99 IDs can be specified for one FILEID. If more than one ID is specified on the FILEID keyword, a log record needs to match only one of the specified file IDs to be included.
TERMID(id1,id2,...)
Specifies that the Journal Print utility use log records only with these terminal IDs. If more than one keyword is specified, for example; INCLUDE FILEID(DD1),TERMID(TST1), the log record must match both IDs specified for it to be included.
Id1,id2,...
Specifies the TERMINALID defined to CICS.For example; id1, id2, can be 1 to 4 characters. Up to 99 IDs can be specified for one TERMID. If more than one ID is specified on the TERMID keyword, a log record needs to match only one of the specified terminal IDs to be included.
TRANSID(id1,id2,...)
Specifies that the Journal Print utility use log records only with these transaction IDs. If more than one keyword is specified, for example; INCLUDE TRANSID(DD1),TERMID(TST1), the log record must match both IDs specified for it to be included.
Id1,id2,...
Specifies the TRANSACTIONID defined to CICS. id1, id2, for example, can be 1 to 4 characters. Up to 99 IDs can be specified for one TRANSID. If more than one ID is specified on the TRANSID keyword, a log record needs to match only one of the specified transaction IDs to be included.

Usage notes

Sample output reports are provided in the CICS VR User's Guide.
Consider the following when using the EXCLUDE command:
  • At least one keyword must be specified for each EXCLUDE command.
  • Multiple EXCLUDE commands and INCLUDE commands can be specified in the same job step. The Journal Print utility processes a log record against all EXCLUDE commands before it processes the log record against all INCLUDE commands.
  • For each log record, if the EXCLUDE criteria is met, the record is excluded. If the EXCLUDE criteria is not met, the Journal Print utility matches the log record against the next EXCLUDE command.
  • When the log record has been examined against all the EXCLUDE commands, the utility examines the log record against the first INCLUDE command, (if the log record was not excluded by any of the EXCLUDE commands).
  • If the INCLUDE criteria is met the record is used in the utility. If it is not met, the Journal Print utility matches the record against the next INCLUDE command.
  • If the log record does not match any of the INCLUDE commands, do not use the log record. Journal Print utility repeats this process for the next log record by matching it first against the EXCLUDE commands and then the INCLUDE commands.
  • If one or more EXCLUDE commands are entered and no INCLUDE commands are entered, all log records that do not match the entered exclude criteria are printed. For example, if you specify:
    EXCLUDE FILEID(DD1),TERMID(T1)
    The utility ignores log records that have a FILEID of DD1 and TERMINALID of T1. If you want to ignore log records that have a FILEID of DD2 or TERMINALID of T2, specify two EXCLUDE commands as follows:
    EXCLUDE FILEID(DD2)  
    EXCLUDE TERMID(T2)
    There is no limit on the number of EXCLUDE (and INCLUDE) commands that you can specify.
  • You can specify up to 99 IDs on each keyword.
  • If you specify INCLUDE or EXCLUDE commands that eliminate all of the records, no records are printed.
  • Do not specify EXCLUDE and INCLUDE criteria that conflict. For example; INCLUDE FILEID(DD1) and EXCLUDE FILEID(DD1). If conflicting criteria is specified, no records are printed and no error messages are produced.
Consider the following when using the INCLUDE command:
  • Multiple INCLUDE commands and EXCLUDE commands can be specified in the same job step. The Journal Print utility processes a log record against all EXCLUDE commands before it processes the log record against all INCLUDE commands.
  • For each log record, if the EXCLUDE criteria is met, the record is excluded. If the EXCLUDE criteria is not met, the Journal Print utility matches the log record against the next EXCLUDE command.
  • When the log record has been examined against all the EXCLUDE commands, the Journal Print utility examines the log record against the first INCLUDE command (if the log record was not excluded by any of the EXCLUDE commands).
  • If the INCLUDE criteria is met, or if no INCLUDE commands were specified, the record is printed.
  • If the criteria it is not met, the Journal Print utility matches the record against the next INCLUDE command. If the log record does not match any of the INCLUDE commands, the log record is not printed. The Journal Print utility repeats this process for the next log record by first matching it against the EXCLUDE commands and then the INCLUDE commands.
  • If one or more INCLUDE commands are entered and no EXCLUDE commands are entered, all log records that match the entered include criteria is printed. For example, if you specify:
    INCLUDE FILEID(DD1),TERMID(T1)
    The Journal Print utility only uses log records that have a FILEID of DD1 and TERMINALID of T1. If you want the Journal Print utility to use log records that have a FILEID of only DD1 or TERMINALID of T1, specify two INCLUDE commands as follows:
    INCLUDE FILEID(DD1)  
    INCLUDE TERMID(T1)
    There is no limitation on the number of INCLUDE (and EXCLUDE) commands.
  • You can specify up to 99 IDs on each keyword.
  • If you specify INCLUDE or EXCLUDE commands that eliminate all of the records, no records are printed.
  • Avoid specifying INCLUDE and EXCLUDE criteria that conflict (for example, INCLUDE FILEID(DD1) and EXCLUDE FILEID(DD1)). If conflicting criteria is specified, no records are printed. No error messages are produced.

Examples

The CICS VR Journal Print Utility can be started by submitting a batch job that runs the utility program, DWWJUP.

The following example shows the use of the PRINT ALL command to print the named data set from the MVS log:
Figure 1. Print the MVS log
//*-------------------------------------------------------*/
//* Print the mvslog                                      */
//*-------------------------------------------------------*/
//PRIINT   JOB ,CICSVR,MSGCLASS=H,CLASS=A,MSGLEVEL=(1,1),
//             REGION=4096K,NOTIFY=USERID
//PRINTLOG EXEC PGM=DWWJUP
//STEPLIB  DD DSN=DWW.SDWWLOAD,DISP=SHR   /* CICSVR LOADLIB */
// DD DSN=DWW.SDWWLENU,DISP=SHR
//DWWPRINT DD SYSOUT=*
//DWWMSG   DD SYSOUT=*
//DWWIN    DD *
   PRINT ALL NAME(CICS.MVSLOG1)
//*
The following example shows the use of the PRINT CICSVR COPY command to print a QSAM copy of the MVS log, specified by the DWWLOG ddname:
Figure 2. Print a QSAM copy of the MVS log
//*-------------------------------------------------------*/
//* Print the copy of the mvslog                          */
//*-------------------------------------------------------*/
//PRIINT   JOB ,CICSVR,MSGCLASS=H,CLASS=A,MSGLEVEL=(1,1),
//             REGION=4096K,NOTIFY=USERID
//PRINTLOG EXEC PGM=DWWJUP
//STEPLIB  DD DSN=DWW.SDWWLOAD,DISP=SHR   /* CICSVR LOADLIB */
// DD DSN=DWW.SDWWLENU,DISP=SHR
//DWWPRINT DD SYSOUT=*
//DWWMSG   DD SYSOUT=*
//DWWLOG   DD DSN=DWW.LOGCOPY,DISP=SHR      /* COPY OF THE MVSLOG */
//DWWIN    DD *
   PRINT CICSVR COPY
//*

The Journal Print Utility filtering is started by adding EXCLUDE and INCLUDE, or EXCLUDE or INCLUDE commands to the command input in the DWWIN dd statement.

Assume the two EXCLUDE commands below are specified in one job step. The two EXCLUDE commands tell the Journal Print utility to exclude all records that have both a FILEID of DD3 and TRANSACTIONID of APQ4, or, exclude all records that have a TERMINALID of TST2
EXCLUDE FILEID(DD3) TRANSACTIONID(APQ4) 
EXCLUDE TERMINALID(TST2)
Assume the five commands below are specified in one job step. Since multiple EXCLUDE and INCLUDE commands are specified in one step, the Journal Print utility processes a log record against all EXCLUDE commands before the log record is processed against all INCLUDE commands.
INCLUDE FILEID(DD1,DD2)  
INCLUDE FILEID(DD3) TERMINALID(TST1)   
INCLUDE FILEID(DD4) TRANSACTIONID(APQ1,APQ2,APQ3)  
EXCLUDE FILEID(DD3) TRANSACTIONID(APQ4)  
EXCLUDE TERMINALID(TST2)

Exclude all records that have both a FILEID of DD3 and TRANSACTIONID of APQ4, or exclude all records that have a TERMINALID of TST2.

This example is exactly like the previous example. When the log record has been processed using the exclude criteria, it is processed using the include criteria. If the log record was not excluded by the EXCLUDE command:

Include all records that have a FILEID of DD1 or DD2, or include all records that have a FILEID of DD3 and TERMINALID of TST1, or Include all records that have a FILEID of DD4 and TRANSACTIONID of APQ1, APQ2, or APQ3

Assume the two INCLUDE commands below are specified in one job step. The two INCLUDE commands tell the Journal Print utility to include all records that have both a FILEID of DD3 and TRANSACTIONID of APQ4, or, include all records that have a TERMINALID of TST2
INCLUDE FILEID(DD1)  
INCLUDE TERMID(T1)
Assume the five commands below are specified in one job step. Since multiple INCLUDE or EXCLUDE commands are specified in one step, the Journal Print utility processes a log record against all EXCLUDE commands before the log record is processed against all INCLUDE commands.
INCLUDE FILEID(DD1,DD2)  
INCLUDE FILEID(DD3) TERMINALID(TST1)  
INCLUDE FILEID(DD4) TRANSACTIONID(APQ1,APQ2,APQ3)  
EXCLUDE FILEID(DD3) TRANSACTIONID(APQ4)  
EXCLUDE TERMINALID(TST2) 

Exclude all records that have both a FILEID of DD3 and TRANSACTIONID of APQ4, or Exclude all records that have a TERMINALID of TST2.

If the log record was not excluded by any of the EXCLUDE commands, it is processed using the include criteria. For the remaining records (the log records that were not excluded by the EXCLUDE command).

Include all records that have a FILEID of DD1 or DD2, or| Include all records that have a FILEID of DD3 and TERMINALID of TST1, or Include all records that have a FILEID of DD4 and TRANSACTIONID of APQ1, APQ2, or APQ3

Synonyms

Table 1. Synonyms for EXCLUDE and INCLUDE commands or keywords
Keyword Synonym
FILEID DD, DDNAME
TERMID TERMINALID
TRANSID TRANSACTIONID

Reference Reference

Feedback


Timestamp icon Last updated: Friday, 29 November 2013


http://pic.dhe.ibm.com/infocenter/cicsts/v5r1/topic///dwwig/printinformationaboutrecordsloggedbycicsvr.html