MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Copyinf files in REXX program

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
Sarangadhar
Beginner


Joined: 14 Oct 2004
Posts: 130
Topics: 43
Location: virtual village

PostPosted: Mon Dec 06, 2004 3:02 pm    Post subject: Copyinf files in REXX program Reply with quote

Hi,
I want to copy PS to another PS since Rename command is failed in my system. Can any one suggest how to copy.
_________________
Thanks
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Dec 06, 2004 3:14 pm    Post subject: Reply with quote

Sarangadhar,

Quote:

since Rename command is failed in my system


What do you mean it rename command failed? post the error code.

Also is there any special reason that you want to use rexx to copy the ps? why don't you use a IEBGENER, IDCAMS or SORT?

Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Sarangadhar
Beginner


Joined: 14 Oct 2004
Posts: 130
Topics: 43
Location: virtual village

PostPosted: Mon Dec 06, 2004 3:25 pm    Post subject: Reply with quote

Kolusu,
Rename commandin REXX program is returning RC=8. It had been working for 2 years, but not from 1 month. May be some system profiles changed. So I planned to copy.

Why I chosed REXX only: I wanted to copy files that start with 2 qualifiers like
all/n files QUAL1.QUAL2.* to some mentioned datasets.

Earlier program renames all existing n files QUAL1.QUAL2.* to some other qualifiers names due to access problems. Now it's not working. Even my TSO RENAME command is not working now.

I already have REXX program to identify n files of that qualifiers. I just wanted copy/rename them.
_________________
Thanks
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Dec 06, 2004 3:32 pm    Post subject: Reply with quote

Sarangadhar,

Run the following rename job and look for the error messages in SYSTSPRT sysout.

Code:

//STEP0100 EXEC PGM=IKJEFT01,DYNAMNBR=20               
//SYSTSPRT DD  SYSOUT=*,DCB=BLKSIZE=121                 
//SYSPRINT DD  SYSOUT=*                                 
//SYSTSOUT DD  SYSOUT=*                                 
//SYSTSIN  DD  *
REN 'YOUR ORGINAL DATASET'-     
    'YOUR RENAME DATASET'
/*


Quote:

Why I chosed REXX only: I wanted to copy files that start with 2 qualifiers like
all/n files QUAL1.QUAL2.* to some mentioned datasets.


Did you try ADRDSSU utility?

Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Sarangadhar
Beginner


Joined: 14 Oct 2004
Posts: 130
Topics: 43
Location: virtual village

PostPosted: Mon Dec 06, 2004 3:52 pm    Post subject: Reply with quote

Kolusu,
Renaming job is working fine.

I think ADRDSSU is used to copy data from one DASD volume to another.
(I don't know the last qualifier of the files, I know only 1st and 2nd qualifiers of source files to get renames, because it is a general program)
_________________
Thanks
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Dec 06, 2004 3:58 pm    Post subject: Reply with quote

Sarangadhar,

You can use ADRDSSU to rename the datasets also. check this link

http://www.mvsforums.com/helpboards/viewtopic.php?t=3183&highlight=adrdssu

Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Sarangadhar
Beginner


Joined: 14 Oct 2004
Posts: 130
Topics: 43
Location: virtual village

PostPosted: Mon Dec 06, 2004 4:20 pm    Post subject: Reply with quote

Kolusu,
Is there any way to supply input file names to this JCL from a file which contain fiels names of all files to get renamed?

//STEP0100 EXEC PGM=IKJEFT01,DYNAMNBR=20
//SYSTSPRT DD SYSOUT=*,DCB=BLKSIZE=121
//SYSPRINT DD SYSOUT=*
//SYSTSOUT DD SYSOUT=*
//SYSTSIN DD *
REN 'dsname1'-
'dsname2'
//*
_________________
Thanks
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Mon Dec 06, 2004 4:21 pm    Post subject: Reply with quote

Sarangadhar,

Quote:

Is there any way to supply input file names to this JCL from a file which contain fiels names of all files to get renamed?


Can you explain in detail as to what you are trying to do ? You can multiple rename cards like as shown below
Code:

//SYSTSIN DD *
REN 'dsname1'-
    'dsname2'
REN 'dsname3'-
    'dsname4'
REN 'dsname5'-
    'dsname6'
...
/*


Hope this helps...

Cheers

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Sarangadhar
Beginner


Joined: 14 Oct 2004
Posts: 130
Topics: 43
Location: virtual village

PostPosted: Mon Dec 06, 2004 4:26 pm    Post subject: Reply with quote

kOLUSU,
I can't have the filenames exactly, last qualifiers get changes daily. I can have only 1st and 2nd qualifiers. I want to rename/copy these to other names. Target name is fixed one, I can give exactly.

Here is my situation: There are 7 files coming daily from some other application, I wanted to get rename these 7 files. I know only 1st and 2nd qualifiers of these 7 input files. 3rd qualifier get changes daily.
_________________
Thanks
Back to top
View user's profile Send private message
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12378
Topics: 75
Location: San Jose

PostPosted: Tue Dec 07, 2004 8:59 am    Post subject: Reply with quote

Sarangdhar,

You can use ADRDSSu for renaming with partial qualifiers. Check the link above which explains about renaming the datasets with partial qualifier list.

Thanks

Kolusu
_________________
Kolusu
www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group