Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Copy GDG(more than 1 version) to PS file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
ajit sahu

New User


Joined: 06 Aug 2013
Posts: 3
Location: india

PostPosted: Mon Oct 28, 2013 11:44 pm    Post subject: Copy GDG(more than 1 version) to PS file
Reply with quote

HI,

I want to copy different GDG version to a PS file. I tried givin GDG base alone in the input file, so that it can read all GDG version availables( AS i dont know How many versions will be present).

The real problem , I am facing is , it is copying GDG starting from +0 till -10 ( latest first and oldest last), But I want to copy Oldest (V-10) to lates +0 version..

IS it possible by any utility to copy from Oldest version to latest version by giving Base alone , Or i need to manually specify the GDG ?

This is what I am coding:

Exec PGM = SORT/IEBCOPY ( I tried with both)
file in = GDG base
Fiel out = PS file:

Expected result:
GDG version copied
-2
-1
0

Actual result :
0
-1
-2
How i can get the expected oen?? is there any utility ??
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Mon Oct 28, 2013 11:55 pm    Post subject:
Reply with quote

Hello and welcome to the forum,

No, there is no automagic utility.

This Has been asked recently and using the forum SEARCH you shoule be aboe to fine these discussions.

Basically, you need to get a list of these and generate JCL in the order you need.

Also, you are not using versions, but rather Generations.
Back to top
View user's profile Send private message
ajit sahu

New User


Joined: 06 Aug 2013
Posts: 3
Location: india

PostPosted: Tue Oct 29, 2013 12:12 am    Post subject: Reply to: Copy GDG(more than 1 version) to PS file
Reply with quote

Thanks for the reply.

Yes, pls read it as generation instead of version. I was searching shortcut as i was not sure how many genrations will be present . But, I believe I need to code my JCL accordingly in absence of utility.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Tue Oct 29, 2013 8:55 pm    Post subject:
Reply with quote

Hello,

Yes, you will need to create the needed JCL. It can be automated rather than doing it by hand every run. . .

The method has been posted before and if you look a bit, you should be able to get it.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Tue Oct 29, 2013 10:40 pm    Post subject:
Reply with quote

If you give GDG Base as input to a 'COPY operation', it will copy all the generations associated with it. However, the records are copied will be in last in, first out order (LIFO) as has been mentioned.

If you want the records copied in first in, first out order (FIFO), so that the records of the first generation will appear first, followed by the records of the second generation and so on, you can also use the smart DFSORT trick " Copy GDG records in first in, first out order" which is shown here http://www-01.ibm.com/support/docview.wss?rs=114&uid=isg3T7000094 .
Back to top
View user's profile Send private message
ajit sahu

New User


Joined: 06 Aug 2013
Posts: 3
Location: india

PostPosted: Thu Oct 31, 2013 12:35 am    Post subject: Reply to: Copy GDG(more than 1 version) to PS file
Reply with quote

Thanks Anuj.. it helped me a lot..
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Oct 31, 2013 1:14 pm    Post subject:
Reply with quote

Glad that we had been helpful.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts syncsort: copy lines after the keyword shreya19 SYNCSORT 1 Fri Dec 02, 2016 9:47 am
No new posts Add PD field from 2nd file to PD in 1st Sushant Garje DFSORT/ICETOOL 6 Thu Dec 01, 2016 4:32 pm
No new posts File Aid to File Manager conversion murali3955 IBM Tools 4 Thu Nov 24, 2016 3:41 pm
No new posts How to convert the VBM file to VB or... Sulabh Agrawal JCL & VSAM 4 Fri Nov 18, 2016 1:04 pm
No new posts CICS Roll back partially - Need to re... dwijadas CICS 4 Wed Nov 16, 2016 4:30 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us