Example 21: Using MODIFY to delete copies from the MVS catalog
This job example uses MODIFY to delete copies from the MVS catalog.
//ACPEX21 JOB (PACP),'EXAMPLE 21',CLASS=Q,MSGCLASS=X,NOTIFY=&SYSUID
//**********************************************************************
//*
//* Run MODIFY to delete entries from SYSIBM.SYSCOPY and BMCXCOPY
//* that are more than 30 days old, and entries whose associated
//* image copy data set no longer exists.
//*
//* This example demonstrates the following features of COPY PLUS:
//*
//* - Restart parm NEW/RESET to allow the job to be restarted from
//* the beginning by re-submitting the job without changes.
//* - Wildcarding in the TABLESPACE specification
//* - AGE to delete SYSIBM.SYSCOPY and BMCXCOPY entries that are
//* older than the number of days specified.
//* - DSNOTFOUND to delete uncataloged image copies from
//* SYSIBM.SYSCOPY and BMCXCOPY.
//*
//**********************************************************************
//BMCCOPY EXEC PGM=ACPMAIN,REGION=0M,
// PARM='DGA,ACPEX21,NEW/RESET,MSGLEVEL(1)'
//STEPLIB DD DISP=SHR,DSN=product.libraries
// DD DISP=SHR,DSN=DB2.DSNEXIT
// DD DISP=SHR,DSN=DB2.DSNLOAD
//ACPERROR DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
MODIFY TABLESPACE ACPEXDB*.*
DELETE WHERE AGE(30)
OR DSNOTFOUND
/*
//**********************************************************************
//*
//* Run MODIFY to delete entries from SYSIBM.SYSCOPY and BMCXCOPY
//* that are more than 30 days old, and entries whose associated
//* image copy data set no longer exists.
//*
//* This example demonstrates the following features of COPY PLUS:
//*
//* - Restart parm NEW/RESET to allow the job to be restarted from
//* the beginning by re-submitting the job without changes.
//* - Wildcarding in the TABLESPACE specification
//* - AGE to delete SYSIBM.SYSCOPY and BMCXCOPY entries that are
//* older than the number of days specified.
//* - DSNOTFOUND to delete uncataloged image copies from
//* SYSIBM.SYSCOPY and BMCXCOPY.
//*
//**********************************************************************
//BMCCOPY EXEC PGM=ACPMAIN,REGION=0M,
// PARM='DGA,ACPEX21,NEW/RESET,MSGLEVEL(1)'
//STEPLIB DD DISP=SHR,DSN=product.libraries
// DD DISP=SHR,DSN=DB2.DSNEXIT
// DD DISP=SHR,DSN=DB2.DSNLOAD
//ACPERROR DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
MODIFY TABLESPACE ACPEXDB*.*
DELETE WHERE AGE(30)
OR DSNOTFOUND
/*
Related topic
Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*