Why not pass the the version in as a symbolic: //ABC PROC VER=620 //PGMNAME EXEC PGM=PGM //STEPLIB DD DNS=LOADMOD.V&ver
Then you can call it from your JCL: //STEP1 EXEC PROC=ABC,VER=620 or //STEP1 EXEC PROC=ABC (This will default to 620) and then if you have a new version, you can change some JCL: //STEP2 EXEC PROC=ABC,VER=710 Another option, if you want to change the version all at once, is to use dataset alias definitions. To do this, you set your proc up like this: //ABC PROC //PGMNAME EXEC PGM=PGM //STEPLIB DD DNS=LOADMOD.PROD.VERSION Then, your JCL would have only this: //STEP1 EXEC PROC=ABC To set this up, you would use IDCAMS like this: //STEP0 EXEC PGM=IDCAMS //SYSPRINT DD SYSOUT=* //SYSIN DD * DEL LOADMOD.PROD.VERSION ALIAS DEF ALIAS(NAME(LOADMOD.PROD.VERSION) - REL(LOADMOD.V620)) That way, everyone who uses LOADMOD.PROD.VERSION, in JCL or ISPF browse, etc, will automatically get LOADMOD.V620. Then, when you want to upgrade, you just run the IDCAMS for the new version: //STEP0 EXEC PGM=IDCAMS //SYSPRINT DD SYSOUT=* //SYSIN DD * DEL LOADMOD.PROD.VERSION ALIAS DEF ALIAS(NAME(LOADMOD.PROD.VERSION) - REL(LOADMOD.V710)) Your proc doesn't need to change, your JCL doesn't change, any CLIST or REXX programs don't change, and everything processes the same way, just on a different version. Of course before you upgrade, you can perform testing by either using a JCL STEPLIB override to the absolute version, or you can define an alias of LOADMOD.TEST.VERSION... This will give you a lot of options, if this is what you are looking for. I hope this is some help to you. Billy On Wed, Apr 18, 2012 at 9:02 AM, Victor Zhang <victor_wor...@yahoo.com.cn>wrote: > Ok, the proc is like: > //ABC PROC VER='620' > //PGMNAME EXEC PGM=PGM > //STEPLIB DD DNS=LOADMOD.V620 > > IF VER NOT = '620' i want proc be: > //PGMNAME EXEC PGM=PGM > //STEPLIB DD DNS=LOADMOD.V710 > > So I code: > //ABC PROC VER='620' > //IF620 IF (&VER=620) THEN > //PGMNAME EXEC PGM=PGM > //STEPLIB DD DNS=LOADMOD.V620 > // ELSE > //PGMNAME EXEC PGM=PGM > //STEPLIB DD DNS=LOADMOD.V710 > // ENDIF > > But it does not work. > > Please help. > > ---------------------------------------------------------------------- > For IBM-MAIN subscribe / signoff / archive access instructions, > send email to lists...@bama.ua.edu with the message: INFO IBM-MAIN > -- Thank you and best regards, *Billy Ashton* ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: INFO IBM-MAIN