how to copy GDG file to PS file



JES, JES2, JCL utilities, IDCAMS, Compile & Run JCLs, PROCs etc...

how to copy GDG file to PS file

Postby cbhargavi » Thu Mar 21, 2013 5:38 pm

Hello everyone,

Can any one suggest me how to copy a GDG file like GDS.report(+1) into a PS file.
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Re: how to copy GDG file to PS file

 

Re: how to copy GDG file to PS file

Postby Robert Sample » Thu Mar 21, 2013 5:49 pm

Depending upon the generation's organization, use IEBGENER or IEBCOPY or SORT.

This is no different that doing a PDS member copy or sequential copy to a sequential file -- so why are you even posting the question?
Robert Sample
Global moderator
 
Posts: 3367
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 222 times

Re: how to copy GDG file to PS file

Postby NicC » Thu Mar 21, 2013 6:03 pm

The generation concept is a form of NAMING convention not DATA FORMAT.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2690
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 105 times

Re: how to copy GDG file to PS file

Postby c62ap90 » Thu Mar 21, 2013 8:48 pm

This may work for you...

//STEP010  EXEC PGM=IDCAMS                     
//SYSPRINT DD SYSOUT=*                         
//SYSUDUMP DD SYSOUT=*                         
//SYSOUD   DD SYSOUT=*                         
//SYSOUT   DD SYSOUT=*                         
//FILEA    DD DSN=GDS.REPORT(+0),               
//            DISP=SHR                         
//FILEB    DD DSN=GDS.REPORT.PS,               
//            DISP=(NEW,CATLG,DELETE),         
//            UNIT=(TEST,1),                   
//*           VOL=SER=???,                     
//            SPACE=(TRK,(15,30),RLSE),         
//            DCB=(RECFM=FB,LRECL=???,BLKSIZE=0)
//SYSIN   DD *                                 
   REPRO                         -             
      INFILE(FILEA)              -             
      OUTFILE(FILEB)                           
/*                                             
//                                             
c62ap90
 
Posts: 125
Joined: Thu Oct 11, 2012 10:24 pm
Has thanked: 1 time
Been thanked: 6 times

Re: how to copy GDG file to PS file

Postby NicC » Fri Mar 22, 2013 12:53 am

Or you could use ICEGENER or IEBGENER or the COPY option of your sort product. IEB/ICEGENER are favourites as you do not need any control cards.
The problem I have is that people can explain things quickly but I can only comprehend slowly.
Regards
Nic
NicC
Global moderator
 
Posts: 2690
Joined: Sun Jul 04, 2010 12:13 am
Location: Pushing up the daisys (almost)
Has thanked: 4 times
Been thanked: 105 times

Re: how to copy GDG file to PS file

Postby cbhargavi » Fri Mar 22, 2013 2:31 pm

sorry by mistake I posted the another requirement...
I want the jcl to get the latest gdg generation file name in to a ps file not the content of the gdg file.
accept my apologies and please assit me..
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Re: how to copy GDG file to PS file

Postby BillyBoyo » Fri Mar 22, 2013 2:42 pm

Perhaps IDCAMS LISTCAT, with the output going to a dataset not SYSOUT=? You can then format the output dataset to what you want.
BillyBoyo
Global moderator
 
Posts: 3804
Joined: Tue Jan 25, 2011 12:02 am
Has thanked: 22 times
Been thanked: 264 times

Re: how to copy GDG file to PS file

Postby cbhargavi » Fri Mar 22, 2013 3:33 pm

yes,but listcat provides all the generations but i need only latest genaration file name to wrriten to ps file
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Re: how to copy GDG file to PS file

Postby enrico-sorichetti » Fri Mar 22, 2013 3:49 pm

if You search this same forum or http://ibmmainframes.com
You will find quite a few examples on how to do it
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort
enrico-sorichetti
Global moderator
 
Posts: 2644
Joined: Fri Apr 18, 2008 11:25 pm
Has thanked: 0 time
Been thanked: 130 times

Re: how to copy GDG file to PS file

Postby cbhargavi » Fri Mar 22, 2013 5:18 pm

yeah,i found the example...thanks for suggestion.
But i didnt understand about EASYTRIEVE and how to code in jcl...
Can any one provide exact jcl ....
cbhargavi
 
Posts: 20
Joined: Mon Oct 15, 2012 5:43 pm
Has thanked: 0 time
Been thanked: 0 time

Next

Return to JCL

 


  • Related topics
    Replies
    Views
    Last post