Building a HIDAM primary index
When the primary index of a HIDAM database has been broken, you can use IMS™ Index Builder to rebuild it by scanning the prime database or partition, if HALDB.
About this task
If sequential scan is applicable, the primary index build is included in the secondary index step. If hierarchical scan must be applied to rebuild the secondary indexes, preliminary sequential scan of the prime database is needed to rebuild the primary index.
The indexes to be built must be either reusable or deleted/defined by IDCAMS. Because IMS Index Builder rebuilds indexes in VSAM load mode by the control interval (CI), the free space value in the DEFINE CLUSTER command must be low.
Figure 1. Building a HIDAM primary
index
Procedure
To build a HIDAM primary index, define the JCL using the
following example:
Figure 2. Example JCL for building a HIDAM primary index
//IIUBBLD JOB &SYSUID,MSGCLASS=H,REGION=233M,TIME=1339,
// RESTART=*,CLASS=A,NOTIFY=&SYSUID
//*********************************************************************
//* Building a HIDAM Primary Index with IMS IB V3 R1 IIUSMP06 *
//*********************************************************************
//* Provide values for the following variables:
// SET SIIULMOD= Index Builder load library
// SET SHKTLOAD= ITKB load library
// SET RESLIB= IMS RESLIB
// SET MDALIB= IMS MDALIB
// SET DBDLIB= DBD library
// SET RECON1= Recon1 data set name
// SET RECON2= Recon2 data set name
// SET RECON3= Recon3 data set name
//* NOTE: The Index Builder load library and all other datasets
//* concatenated to STEPLIB must be APF authorized.
//*********************************************************************
//IIUBSCN EXEC PGM=IIUSTART
//STEPLIB DD DISP=SHR,DSN=&SIIULMOD
// DD DISP=SHR,DSN=&SHKTLOAD
// DD DISP=SHR,DSN=&RESLIB
// DD DISP=SHR,DSN=&MDALIB
//IMS DD DISP=SHR,DSN=&DBDLIB
//RECON1 DD DISP=SHR,DSN=&RECON1
//RECON2 DD DISP=SHR,DSN=&RECON2
//RECON3 DD DISP=SHR,DSN=&RECON3
//IIUPRINT DD SYSOUT=*
//IIUCAPT DD SYSOUT=*
//IIUSNAP DD SYSOUT=*
//IIUSOUT DD SYSOUT=*
//IIUIN DD *
PROC BLD_PRIMARY,TSTDATA
INPUT IBSCAN
/*
//