BLDINDEX command is used to load records into an AIX cluster. When this command is executed, three distinct functions occur in the following order.
* Records of base cluster are read and alternate
key – pointer pair records are extracted.
* The key – pointer pair records are sorted in
ascending order of the alternate key.
* The alternate index is loaded with these sorted
//AIXDEF JOB (ACCT),’BUILD AIX’
//BLDINDX EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//IDCUT1 DD DSN=SORT.WORK.FILE1, DISP=OLD
//IDCUT2 DD DSN=SORT.WORK.FILE2, DISP=OLD
//SYSIN DD *
INDATASET (STUDENT.KSDS.CLUSTER) –
OUTDATASET (STUDENT.KSDS.AIX1.CLUSTER) –
IDCUT1 & IDCUT2 ~ are sort work files. There are default DD names in the BLDINDEX.
INTERNALSORT ~ indicates that AMS will perform an internal sort of the alternate key – pointer pair if possible. Otherwise an external sort will be performed by using the sort work files.
CATALOG ~ gives the VSAM catalog where the sort work files are defined.