CBRSMPDS

CBRSMPDS, as shown here, performs the migration necessary for the TAPEVOL table, adding a column in support of the new object tape dataset name format. The object tape dataset name format, with SETOAM parmlib specification, allows the storage group name to be appended to the object tape dataset names.

//CBRSMPDS JOB MSGLEVEL=(1,1),MSGCLASS=A
//*********************************************************************
//*
//*  $SEG(CBRSMPDS) COMP(DBM) PROD(OAM):
//*
//*  OAM DB2 Database Migration Jobs (for OAM Configuration
//*  Database).
//*
//*  This job performs the migration of the TAPEVOL table to the
//*  new version of the TAPEVOL table supporting the new object
//*  tape dataset name format.  The object tape dataset name
//*  format, with SETOAM parmlib specification, allows the storage
//*  group name to be appended to the object tape dataset names.
//*
//*  This job adds a new column DSNFMT to the existing TAPEVOL table.
//*
//*  For recovery purposes, it is recommended that you create a
//*  DB2 image copy of the existing TAPEVOL table prior to running
//*  this migration job.
//*
//*  ———————————————————————————————-
//*
//*  Before running this job, you must change the following:
//*
//*  1. Change the name in the DSN SYSTEM(DB2) statement to
//*     the name of the DB2 Subsystem in your installation.
//*
//*  2. Change the PLAN name (DSNTIAxx) in the RUN statement to
//*     match your current DB2 version and release level.
//*
//*  3. Change the data set name in the RUN statement
//*     LIB('DB2.RUNLIB.LOAD') phrase to the data set name used
//*     in your installation for the DB2 RUNLIB.LOAD data set.
//*
//*  ———————————————————————————————-
//*
//*  STEP        DESCRIPTION
//*  ————    —————-
//*
//*  ALTERTVL -  This step adds the new DSNFMT column
//*              to the TAPEVOL table.
//*
//*  LABELTVL -  This step provides the new label for the DSNFMT
//*              column.
//*
//*  ———————————————————————————————-
//*
//*   CHANGE ACTIVITY:
//*    $L0=OA07105  1J0 050504 TUCLJS: 3592 Enterprise WORM Tape
//*
//*********************************************************************
//*  Alter the TAPEVOL table to add the new DSNFMT column.
//*********************************************************************
//ALTERTVL EXEC PGM=IKJEFT01,DYNAMNBR=20
//SYSTSPRT DD SYSOUT=*
//SYSTSIN  DD *
 DSN SYSTEM(DB2)
 RUN  PROGRAM(DSNTIAD) PLAN(DSNTIAxx) -
      LIB('DB2.RUNLIB.LOAD')
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSIN    DD *

 ALTER TABLE TAPEVOL ADD DSNFMT CHAR(1) NOT NULL WITH DEFAULT;

 COMMIT;
/*
//*********************************************************************
//*  Place label on TAPEVOL table DSNFMT column
//*********************************************************************
//LABELTVL EXEC PGM=IKJEFT01,DYNAMNBR=20,COND=(4,LT)
//SYSTSPRT DD SYSOUT=*
//SYSTSIN  DD *
 DSN SYSTEM(DB2)
 RUN  PROGRAM(DSNTIAD) PLAN(DSNTIAxx) -
      LIB('DB2.RUNLIB.LOAD')
//SYSPRINT DD SYSOUT=*
//SYSUDUMP DD SYSOUT=*
//SYSIN    DD *

 LABEL ON TAPEVOL
   (DSNFMT IS 'DATASET_NAME_FORMAT');

 COMMIT;