ALTERMOD


Summary

For basic information, go through the IEBCOPY Utility (for Beginners)

  • The ALTERMOD statement is used to alter load modules that are generated before MVS/370 to make them compatible with the latest system.
  • ALTERMOD statement specifies the beginning of an alter-in-place operation for load modules.
  • ALTERMOD only works with a PDS, not a PDSE.

Syntax -


//SYSIN     DD  *
[label] ALTERMOD OUTDD=DDname
		[LIST={YES|NO}]
/*
  • OUTDD=DDname - Specifies the DDname of the PDS, which contains the load modules to be altered.
  • LIST={YES|NO} - Specify the altered member names to be listed in the SYSPRINT data set. When ignored, the default listing option from the EXEC PARM gets applied.

Practical Example -


Scenario - Alter all members in MATEPK.IEBCOPY.INPLOAD.

JCL -

----+----1----+----2----+----3----+----4----+----5----+----6----+----7--
***************************** Top of Data ******************************
//MATEPKA  JOB (123),'MTH',CLASS=A,MSGCLASS=A,MSGLEVEL=(1,1),           
//             NOTIFY=&SYSUID                                           
//***************************************************                   
//* ALTER ALL LOAD MODULES FROM INPUT PDS                               
//***************************************************                   
//STEP10   EXEC PGM=IEBCOPY                                             
//SYSPRINT DD SYSOUT=*                                                  
//SYSOUT   DD SYSOUT=*                                                  
//SYSDUMP  DD SYSOUT=*                                                  
//SYSUT1   DD DSN=MATEPK.IEBCOPY.INPLOAD,DISP=(OLD,KEEP)                
//SYSUT2   DD UNIT=SYSDA,SPACE=(TRK,(5,1))                              
//SYSIN    DD *                                                         
 ALTERMOD  OUTDD=SYSUT1 LIST=ALL                                        
/*                                                                      
**************************** Bottom of Data ****************************

Output -

ALTERMOD Output

Explaining Example -

  • SYSUT1 DD DSN=MATEPK.IEBCOPY.INPLOAD - Specifies the PDS that has old load modules.
  • SYSUT2 DD - Provides the buffer space to process the operation.
  • SYSIN DD - Has the control statements for processing the input.
  • ALTERMOD OUTDD=SYSUT1 - Used to alter the load module from SYSUT1 DSN.
  • LIST=ALL - Prints altering modules list in SYSPRINT.