IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

how can we copy the bulk dataset using rexx utility


IBM Mainframe Forums -> CLIST & REXX
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
cmsmoon

New User


Joined: 17 Jun 2010
Posts: 75
Location: Chennai

PostPosted: Tue Nov 04, 2014 11:58 am
Reply with quote

Hi ,

The requirement is we need to copy the datasets which the cataloged all the datasets to another datasets which under the below qualifiers.

XMMD01.DEVL.BR10.J* TO XMMD01.PROD.BR10.J*.D110414

how can we to this using REXX commands ?
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Tue Nov 04, 2014 3:58 pm
Reply with quote

IGGCSIRX in SYS1.SAMPLIB is the extreme basic version of the utility which will list any datasets matching the input pattern supplied - which also works with * ** and %.

There is also a bit of code of mine out there CSIUTIL which uses IGGCSIRX and will give you the dataset name, volume, and migrate status.

From there you need to code your own REXX to perform the copies. Sure there are plenty of examples on the forum.

Suggest that you DO NOT use REXX as the copy vehicle but invoke ICEGENER or some other utility to perform the copies.

Also suggest that you do this by submitting to batch rather than locking your terminal for what may be hours.

Or of course if they are all DASD datasets you could do it far quicker and easier using DFdss dump / restore. HRECALL any migrated datasets, dump and restore using rename.
Back to top
View user's profile Send private message
don.leahy

Active Member


Joined: 06 Jul 2010
Posts: 765
Location: Whitby, ON, Canada

PostPosted: Wed Nov 05, 2014 3:38 am
Reply with quote

Another approach is to use ISPF services. LMDLIST can be used to build a list of data sets that match your pattern. LMCOPY can then be used to copy the data set.

(As usual, I have left out a lot of details, some of them very important. With a bit of research the TS should be able to figure it out).
Back to top
View user's profile Send private message
Paul Voyner

New User


Joined: 26 Nov 2012
Posts: 52
Location: UK

PostPosted: Wed Nov 05, 2014 1:02 pm
Reply with quote

I did something similar a while back. Assuming you have DFDSS or FDR ..
1. Do a TYPRUN=NORUN dump or copy to get a list of all your eligible XMMD01.DEVL.BR10.J* datasets
2. Process that SYSPRINT in a REXX to generate RENUNC(olddsn,newdsn) statements for each datasets
3. Use the statements from (2) as SYSIN to a DFDSS COPY job.

(Because DFDSS generic rename processing can't handle changing the number of dsn levels, which is what you seem to want)
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CLIST & REXX

 


Similar Topics
Topic Forum Replies
No new posts Compile Several JCL JOB Through one r... CLIST & REXX 4
No new posts Running REXX through JOB CLIST & REXX 13
No new posts Error to read log with rexx CLIST & REXX 11
No new posts isfline didnt work in rexx at z/OS ve... CLIST & REXX 7
No new posts run rexx code with jcl CLIST & REXX 15
Search our Forums:

Back to Top