Example 20: Using MODIFY to delete uncataloged copies
This job example uses MODIFY to delete uncataloged copies.
//ACPEX20 JOB (PACP),'EXAMPLE 20',CLASS=Q,MSGCLASS=X,NOTIFY=&SYSUID
//**********************************************************************
//*
//* Run MODIFY to delete entries from SYSIBM.SYSCOPY and BMCXCOPY
//* that are older than the third most recent full copy.
//* Image copy data sets associated with the deleted copy entries
//* are deleted from the MVS catalog.
//*
//* Since ANALYZE YES is coded, COPY PLUS reports which entries
//* would be deleted, but no deletes are done.
//*
//* 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
//* - Wildcarding in the EXCLUDE specification
//* - ICFDELETE YES to delete image copy data set that are associated
//* with the copy entries that are being deleted.
//* - ANALYZE YES to cause COPY PLUS to report which entries would
//* would be deleted without deleting anything.
//*
//**********************************************************************
//BMCCOPY EXEC PGM=ACPMAIN,REGION=0M,
// PARM='DGA,ACPEX20,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*.*
EXCLUDE ACPEXDB2.*
DELETE MAXFULLCOPIES(3)
ICFDELETE YES
ANALYZE YES
/*
//**********************************************************************
//*
//* Run MODIFY to delete entries from SYSIBM.SYSCOPY and BMCXCOPY
//* that are older than the third most recent full copy.
//* Image copy data sets associated with the deleted copy entries
//* are deleted from the MVS catalog.
//*
//* Since ANALYZE YES is coded, COPY PLUS reports which entries
//* would be deleted, but no deletes are done.
//*
//* 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
//* - Wildcarding in the EXCLUDE specification
//* - ICFDELETE YES to delete image copy data set that are associated
//* with the copy entries that are being deleted.
//* - ANALYZE YES to cause COPY PLUS to report which entries would
//* would be deleted without deleting anything.
//*
//**********************************************************************
//BMCCOPY EXEC PGM=ACPMAIN,REGION=0M,
// PARM='DGA,ACPEX20,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*.*
EXCLUDE ACPEXDB2.*
DELETE MAXFULLCOPIES(3)
ICFDELETE YES
ANALYZE YES
/*
Related topics
Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*