Page 1 of 1

RENAME member

PostPosted: Tue Sep 15, 2009 1:23 pm
by manesg
I'm trying to rename a member - jcl below

//RENAM JOB (PS),'PS-RENAMEDEL',CLASS=A,MSGCLASS=X,NOTIFY=&SYSUID
//STEP1 EXEC PGM=IEHPROGM
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
RENAME MBOLT.MTEMPX.M7AWXX.DATA04(BATDL) -
MBOLT.MTEMPX.M7AWXX.DATA04(BATDLOLD)
//*


I get the below error in SYSPRINT:
__________
SYSTEM SUPPORT UTILITIES ---- IEHPROGM

RENAME MBOLT.MTEMPX.M7AWXX.DATA04(BATDL) -
IEH202I INVALID KEYWORD OR CONTROL STATEMENT SYNTAX

MBOLT.MTEMPX.M7AWXX.DATA04(BATDLOLD)
IEH201I INVALID REQUEST... STATEMENT IGNORED

UTILITY END
_______

When i replace the keyword RENAME with ALTER in the jcl, i get the following
___________
SYSTEM SUPPORT UTILITIES ---- IEHPROGM

ALTER MBOLT.MTEMPX.M7AWXX.DATA04(BATDL) -
IEH201I INVALID REQUEST... STATEMENT IGNORED

MBOLT.MTEMPX.M7AWXX.DATA04(BATDLOLD)
IEH201I INVALID REQUEST... STATEMENT IGNORED

UTILITY END
________

At first iam trying with one member. Eventually i need to rename couple of members in the same dataset.
(Iam trying to automate this process, as currently iam using the ispf menus to do the same, which is time consuming)
Or any other method?

Any leads?

thanks for your time.

Re: RENAME member using JCL

PostPosted: Tue Sep 15, 2009 2:46 pm
by MrSpock
The two best ways I know of are:

1. The TSO/E RENAME command.

2. The IDCAMS ALTER command.

Re: RENAME member

PostPosted: Wed Sep 16, 2009 11:16 am
by manesg
Thanks Mr Spock.
I used IDCAMS ALTER and successfully renamed the member.

Re: RENAME member

PostPosted: Wed Sep 16, 2009 6:54 pm
by Bill Dennis
IEHPROGM will also work if you use the correct syntax. There is a separate parameter for MEMBER= .

Check in the Utilities manual.

Re: RENAME member

PostPosted: Sun Sep 20, 2009 6:18 pm
by manesg
Thanks Bill.
I shall check the same.