FDREPORT Archive Examples


This section shows examples that read an Archive Control File (DATATYPE=ARCHIVE). All examples in this section are found in the JCL library installed with FDR. The member names are EX5441x.

A sample of the generated report is shown after each example; because of space limitations, it may be condensed. In examples where sorting is required, SORTALLOC=YES has been specified to dynamically allocate required SORT files; in your installation you may have to provide SORT JCL.

Report on expiring data sets example

Report on all data sets in the Archive Control File that expire within the next 30 days, showing information about the location of both archive copies if both exist.

//REPORT EXEC PGM=FDREPORT,REGION=0M //SYSPRINT DD SYSOUT=* //ABRMAP DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //ARCHIVE DD DSN=FDRABR.ARCHIVE,DISP=SHR //SYSIN DD * TITLE LINE='ARCHIVED FILES EXPIRING WITHIN 30 DAYS' XSELECT BKEXDAYS<31 REPORT FIELDS=(DSN,VOL,BKEXDATE,BKINFO) PRINT DATATYPE=ARCHIVE,COPY=BOTH,SORT=YES,SORTALLOC=YES /*

The generated report looks like:

ARCHIVED FILES EXPIRING WITHIN 30 DAYS

BKUP

DATA SET NAME VOLSER BKEDAT BKDATE BKSUFFIX FILE TAPE VOLUME(S) REQUIRED TO RESTORE

------------- ------ -------- -------- -------- ---- ----------------------------------

USER1.FILE1 TSO001 2018.304 2017.304 B102304A 2 BA1234

2018.304 2017.304 B202304A 5 BA5432

USER2.JCL.CNTL TSO023 2018.308 2017.308 B102308B 12 BA1234

Selective archive report example

Report on all archived data sets that have one of several hi-level indexes, summarized by index. A standard archive report is to be printed. The Archive Control File whose name is in the ABR option table is to be dynamically allocated and processed. See Section 53.3 “FDRABRP Archive Report for a sample of the report format.

//REPORT EXEC PGM=FDREPORT,REGION=0M //SYSPRINT DD SYSOUT=* //ABRMAP DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //SYSIN DD * DEFAULT SORT=COMBINE,SUM=INDEX,COPY=BOTH XSELECT DSG=(FINANCE.,PAYROLL.,LEDGER.) PRINT DATATYPE=ARCHIVE,RPTYPE=ARCHIVE,SORTALLOC=YES /*

Report on Short-Term data sets example

Report on all archived data sets that were archived within the last two weeks but that have already been recalled. This might be used to identify data sets that should not have been archived in the first place.

//REPORT EXEC PGM=FDREPORT,REGION=0M //SYSPRINT DD SYSOUT=* //ABRMAP DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //SYSIN DD * TITLE LINE='ARCHIVED DATA SETS RECALLED WITHIN 14 DAYS' DEFAULT DATEFORMAT=MMDDYYYY XSELECT ARCFLAG1=RESTORED,BKDAYS<15 REPORT FIELDS=(DSN,VOL,DSORG,SIZE,BKDATE,ARCFLAGS) PRINT DATATYPE=ARCHIVE /*

The generated report looks like:

ARCHIVED DATA SETS RECALLED WITHIN 14 DAYS

D/S ARC ARC

DATA SET NAME VOLSER ORG ALLOC BKDATE FLAG1 FLAG2

------------- ------ --- -------- ---------- ----- -----

USER1.FILE1 TSO001 PS 22 01/20/2018 R A

USER2.JCL.CNTL TSO023 PS 150 01/22/2018 R

Archive tape report example

Produce a report of the archive tapes in use and the number of archive backup files on each of them.

//REPORT EXEC PGM=FDREPORT,REGION=0M //SYSPRINT DD SYSOUT=* //ABRSUM DD SYSOUT=* //SYSUDUMP DD SYSOUT=* //SYSIN DD * TITLE LINE='ARCHIVE TAPE REPORT' SORT FIELDS=BKVOL SUMMARY FIELDS=BKVOL PRINT DATATYPE=ARCHIVE,COPY=BOTH,SORTALLOCATE=YES,RPTYPE=NONE /*

The generated report looks like:

ARCHIVE TAPE REPORT

FINAL TOTALS --

VALUE SUMMARY OF BKVOL --- TOTAL NUMBER OF VALUES------24

BKVOL-----CCR151 ( 1) DV20FE ( 7) DV20FF ( 70) RVA7C7 ( 2)

SAFEC5 ( 3) SAFEC9 ( 38) SCR081 ( 8) SCR082 ( 5)

SCR083 ( 229) SCR084 ( 1) SCR085 ( 3) SCR087 ( 6)

SCR089 ( 2) SCR093 ( 13) SY3108 ( 2531) 001022 ( 1)

001133 ( 1) 001188 ( 1) 001404 ( 1) 001419 ( 1)

001422 ( 1) 001429 ( 1) 001433 ( 1) 003342 ( 2)

If you want to run the report against a control file that is not the installation default Archive Control File, such as an application backup control file, then add an ARCHIVE DD Statement pointing to the desired control file, for example:

//ARCHIVE DD DSN=APPL.BACKUP.CNTLFILE,DISP=SHR


 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*