Examples for the DFSURUL0 utility
These examples show usage for the DFSURUL0 utility.
The examples in this topic contain the following comment line above the SYSIN statement to aid in column alignment.
//* +----1----+----2----+----3----+----4----+----5----+----6----+----7
This comment line is for reference only, and is not required.
//RECON1 DD DSNAME=RECON1,DISP=SHR
//RECON2 DD DSNAME=RECON2,DISP=SHR
//RECON3 DD DSNAME=RECON3,DISP=SHR
Subsections:
Index work data set
- Unloaded versions of two secondary indexes in a shared secondary index database
- An unloaded version of a third secondary index
//INDREOR JOB 1,1,MSGLEVEL=1
//*
//STEP1 EXEC PGM=DFSRRC00,
// PARM='ULU,DFSURUL0,,,1,,,,,,,,,N,N'
//STEPLIB DD DSN=IMS.SDFSRESL,DISP=SHR
//DFSRESLB DD DSN=IMS.SDFSRESL,DISP=SHR
//IMS DD DSN=IMS.DBDLIB,DISP=SHR
//SYSPRINT DD SYSOUT=A,DCB=BLKSIZE=1330
//DBIDX1 DD DSN=IMS.INDX1,DISP=SHR
//DXOUT1 DD DSN=IMS.DBXOUT1,DISP=(MOD,KEEP),
// UNIT=TAPE,VOL=SER=DXOUT1,LABEL=(,SL)
//DBIDX2 DD DSN=IMS.INDX2,DISP=SHR
//DXOUT2 DD DSN=IMS.DBXOUT2,DISP=(,KEEP),
// UNIT=TAPE,VOL=SER=DXOUT2,LABEL=(,SL)
//NDXDS DD DSN=IMS.NDXWDS,DISP=(OLD,DELETE)
//DFSVSAMP DD input for VSAM and OSAM buffers and options
//* +----1----+----2----+----3----+----4----+----5----+----6----+----7
//SYSIN DD *
OPTIONS=(NSTAT,ABEND)
X1MDIX1DB01 DBIDX1 DXOUT1 NDXDS CREATE NEW SECONDARY
INDEX
X1MDIX1DB02 DBIDX1 DXOUT1 NDXDS ADD SECONDARY INDEX RECS
TO EXISTING ONE ABOVE
X1MDIX2DB01 DBIDX2 DXOUT2 NDXDS RECORDS FROM SAME WORK
DS PUT INTO DIFFERENT
DATABASE
/*
The output of the example is used as input to the HISAM Reorganization Reload utility to create the secondary indexes. The Access Method Services utility must have been run to create the secondary index databases.
DBRC and IRLM are turned off in the EXEC PARM statement. The OPTIONS statement specifies that statistics are not wanted and that any serious message causes an abend U0359.
Extract, replace, and merge index records
In this example, a group of index records that had a constant of 'B' defined in the DBDGEN for the shared index is to be extracted, replaced, and merged. The options are to be changed between operations to have statistics on first, none on the second and statistics again on the third. The ABEND option is changed on the second OPTIONS statement.
//IDEREORG JOB 1,1,MSGLEVEL=1
//*
//STEP1 EXEC PGM=DFSRRC00,PARM='ULU,DFSURUL0'
//STEPLIB DD DSN=IMS.SDFSRESL,DISP=SHR
//DFSRESLB DD DSN=IMS.SDFSRESL,DISP=SHR
//IMS DD DSN=IMS.DBDLIB,DISP=SHR
//SYSPRINT DD SYSOUT=A,DCB=BLKSIZE=1330
//DBIDX2 DD DSN=IMS.INDX2,DISP=SHR
//DBIDX1 DD DSN=IMS.INDX1,DISP=SHR
//DBXOUT1 DD DSN=IMS.DBXOUT1,DISP=(MOD,KEEP),
// UNIT=TAPE,VOL=SER=DXOUT1,LABEL(,SL)
//DFSEXTDS DD DSN=IMS.EXTDS1,DISP=(MOD,KEEP),
// UNIT=TAPE,VOL=SER=DEXTDS,LABEL=(,SL)
//NDXWDS1 DD DSN=IMS.XWDS1,DISP=(OLD,PASS)
//NDXWDS2 DD DSN=IMS.XWDS2,DISP=(OLD,PASS)
//NDXWDS3 DD DSN=IMS.XWDS3,DISP=(OLD,PASS)
//* +----1----+----2----+----3----+----4----+----5----+----6----+----7
//SYSIN DD *
OPTIONS=(STATS,ABEND)
X1EDIX3DB01 DBIDX1 DBXOUT1 NDXWDS1 BUNLOAD INDEX EXTRACT
THOSE MARKED WITH
CONSTANT B INCLUDING
THOSE ON WORK DATA SET
OPTIONS=(ABENDOFF,NSTAT)
X1RDIX4DB01 DBIDX2 DBXOUT1 NDXWDS2 BUNLOAD INDEX REPLACING
THOSE HAVING CONSTANT B
WITH THOSE FROM INDEX
WORK DATA SET
OPTIONS=(STATS,ABEND)
X1MDIX4DB02 DBIDX2 DBXOUT1 NDXWDS3 MERGE ALL RECS OF WORK
DATA SET AND CREATE A
SHARED INDEX
/*
//DFSVSAMP DD *
1024,10
/*
Create and merge secondary indexes, replace constants, and prepare for a HISAM Reorganization Reload utility usage
- Create two output data sets to be used to create two separate secondary indexes
- Merge two secondary indexes by merging an index work data set created by the Prefix Resolution utility with an existing secondary index (which was created previously as a shared secondary index having only one constant)
- Replace the one constant already in the shared secondary index with the constants in the index work data sets
- Extract a constant from a shared index and put it in a form that can be used by the HISAM Reorganization Reload utility to create another separate secondary index
Each operation is separated by an OPTIONS statement. Although the JCL is shown only once here, each operation is considered a separate run. To perform all operations in one run, DISP=MOD must be specified for DBOUT1 and DBOUT2.
//INDXREOR JOB 1,1,MSGLEVEL=1
//*
//STEP1 EXEC PGM=DFSRRC00,PARM='ULU,DFSURUL0'
//STEPLIB DD DSN=IMS.SDFSRESL,DISP=SHR
//DFSRESLB DD DSN=IMS.SDFSRESL,DISP=SHR
//IMS DD DSN=IMS.DBDLIB,DISP=SHR
//SYSPRINT DD SYSOUT=A,DCB=BLKSIZE=1330
//DBIX1A DD DSN=IMS.DBIX1A,DISP=OLD
//DBIX2B DD DSN=IMS.DBIX2B,DISP=OLD
//DBOUT1 DD DSN=IMS.DBOUT1A,DISP=(,KEEP),
// UNIT=SYSDA,SPACE=(CYL,(2,1))
//DBOUT2 DD DSN=IMS.DBOUT2A,DISP=(,KEEP),
// VOL=SER=DBOUT2,LABEL=(,SL)
//INDXWDS1 DD DSN=IMS.INDXWDS1,DISP=(OLD,DELETE)
//INDXWDS2 DD DSN=IMS.INDXWDS2,DISP=(OLD,DELETE)
//DFSEXTDS DD DSN=IMS.EXTSD1,DISP=(,KEEP),
// VOL=SER=EXTDS1,LABEL=(,SL)
//* +----1----+----2----+----3----+----4----+----5----+----6----+----7
//SYSIN DD *
X1MDI32XDB1 DBIX1A DBOUT1 INDXWDS1 DBIX1A TO BE CREATED
X1MDI33XDB2 DBIX2B DBOUT2 INDXWDS2 DBIX2B TO BE CREATED
OPTIONS=(STATS,ABEND)
X1MDI32XDB1 DBIX1A DBOUT1 INDXWDS2 MERGE ONE EXISTING
WITH NEW OPTIONS=(NSTAT,ABENDOFF)
X2RDI32XDB1 DBIX1A DBOUT1 DBOUT2 INDXWDS1 AREPLACE ANY EXISTING
A'S WITH ONES FROM
WORK DATA SET OPTIONS=STATS
X1EDI32XDB1 DBIX1A DBOUT1 INDXWSD2 BTAKE B CONSTANTS FROM
SHARED INDX AND/OR
WORK DATA SET AND PUT
OUT TO DFSEXTDS DD
STATEMENT
/*
//DFSVSAMP DD *
1024,10
/*