Define Path for AIX
IDCAMS Define Path for AIX Example
Scenario - Define path for alternate index on the employee KSDS file.
Input KSDS File - MATEPK.EMPL.KSDS
Input Alternate Index - MATEPK.EMPL.DEPTAIX
JCL -
----+----1----+----2----+----3----+----4----+----5----+
//MATEPKP JOB (123),'MTH',CLASS=A,MSGCLASS=A,
// MSGLEVEL=(1,1),NOTIFY=&SYSUID
//********************************************
//* DEFINE PATH
//********************************************
//STEP10 EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
DEFINE PATH (NAME(MATEPK.EMPL.DEPTAIX.PATH) -
PATHENTRY(MATEPK.EMPL.DEPTAIX) -
UPDATE)
/*
Output -
Once the above JCL is submitted, check the MAXCC of the job for any errors. If the MAXCC is 00 or 04, then DEFINE PATH is successful.
The PATH should load with all the keys from the base cluster, and the alternate key should highlight as shown below -
Explaining Example -
In the above example,
- NAME(MATEPK.EMPL.DEPTAIX.PATH) specifies the AIX path.
- PATHENTRY(MATEPK.EMPL.DEPTAIX) specifies alternate index defined earlier.
- UPDATE specifies the alternate indexes should be updated when records are added, modified, or deleted to the base cluster.