In addition, you can use MFDBUJCL to execute the Rebuild utility.
//step EXEC PGM=MFDBUJCL,PARM='{LOAD | UNLOAD | ADD},database,dataset' //SYSOUT DD SYSOUT=*
//step EXEC PGM=MFDBUJCL,PARM='{LOAD | ADD},database' //SYSOUT DD SYSOUT=* //INPUT DD DSN={dataset | catalog},DISP=SHR
//step EXEC PGM=MFDBUJCL,PARM='UNLOAD,database' //SYSOUT DD SYSOUT=* //OUTPUT DD DSN={dataset | catalog},DISP=SHR
//step EXEC PGM=MFDBUJCL,PARM='{ZEROLOAD | PTRUPDATE},database' //SYSOUT DD SYSOUT=*
//step EXEC PGM=MFDBUJCL,PARM='REBUILD' //SYSOUT DD SYSOUT=* //SYSIN DD * [OUT-PATH=dbrebuildpath] databasename1 [databasenameN ...] /*
If your dataset is not contained in a JCL catalog, use Format 1 for LOAD, UNLOAD, and ADD functions.
If your dataset is contained in a JCL catalog, you can optionally use Format 2 for LOAD and ADD functions, and Format 3 for the UNLOAD function.
//LOAD EXEC PGM=MFDBUJCL,PARM='LOAD,DEMO03DD,LOAD.DBU' //SYSOUT DD SYSOUT=* //UNLOAD EXEC PGM=MFDBUJCL,PARM='UNLOAD,DEMO03DD,LOAD.DBU' //SYSOUT DD SYSOUT=* //ADD EXEC PGM=MFDBUJCL,PARM='ADD,DEMO03DD,LOAD.DAT' //SYSOUT DD SYSOUT=*
//LOAD EXEC PGM=MFDBUJCL,PARM='LOAD,DEMO03DD' //SYSOUT DD SYSOUT=* //INPUT DD DSN=HLQ.PRJ01.LOAD. DEMO03DD,DISP=SHR //ADD EXEC PGM=MFDBUJCL,PARM='ADD,DEMO03DD’ //SYSOUT DD SYSOUT=* //INPUT DD DSN=HLQ.PRJ01.ADD. DEMO03DD,DISP=SHR
//UNLOAD EXEC PGM=MFDBUJCL,PARM='UNLOAD,DEMO03DD' //SYSOUT DD SYSOUT=* //OUTPUT DD DSN=HLQ.PRJ01.UNLOAD. DEMO03DD,DISP=SHR
//PTRUPDT EXEC PGM=MFDBUJCL,PARM='PTRUPDATE,DEMO03DD’ //SYSOUT DD SYSOUT=* //PTRUPDT EXEC PGM=MFDBUJCL,PARM='PTRUPDATE,DEMO03DD’ //SYSOUT DD SYSOUT=*
//STEP01 EXEC PGM=MFDBUJCL,PARM='REBUILD' //SYSOUT DD SYSOUT=* //SYSIN DD * OUT-PATH=C:\IMS\REBUILT\DATABASES BNKCUST BNKACC BNKATYPE /* //