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

need to put the gdg version name on the Easytrieve report


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
venugopal404

New User


Joined: 14 Dec 2010
Posts: 13
Location: hyderabad

PostPosted: Wed Jun 06, 2012 6:20 pm
Reply with quote

Hi All,
I'm not sure whether posting this in JCL forum's is correct or not.sorry if im posting it in a wrong place.

we have a requirement where we need to put the GDG Version name on the easytrieve report.

To explain in detail,my JCL has two steps..
step1 will produce a gdg version ex: MY.GDG.G0140V00.

In step2: We have a easy-trieve Program which uses the GDG version
(MY.GDG.G0140V00) which got created in step1 and creates a report.
now this report should contain the GDG Version name in the report heading line.
MY JCL looks like below..
Code:

//STEP1  EXEC  PGM=ICEGENER                       
//SYSUT1   DD  DSN=XXX.YYY.ZZZ,DISP=SHR           
//SYSUT2   DD  DSN=MY.GDG(+1),                   
//*** HERE IT CREATES (MY.GDG.G0140V00) VERSION   
//             DISP=(NEW,CATLG,,DATACLAS=MB050,   
//             DCB=(LRECL=900,BLKSIZE=0,RECFM=FB)
//SYSPRINT DD  SYSOUT=*                           
//SYSIN    DD  DUMMY                             
//*                                               
//STEP2  EXEC  PGM=ABC                           
//STEPLIB DD DSN=XYZ.LINKLIB,DISP=SHR             
//SYSPRINT DD SYSOUT=*                           
//SYSOUT   DD SYSOUT=*                           
//SYSUDUMP DD SYSOUT=*                           
//INFILE   DD  DISP=SHR,DSN=MY.GDG(+1)           
//REPORTA  DD  DSN=MY.GDG.REPORT(+1),             
//             DISP=(NEW,CATLG,,DATACLAS=MB050,   
//             DCB=(LRECL=900,BLKSIZE=0,RECFM=FBA)


sample output:
Code:

1        REPORT FROM FILE - MY.GDG.G0140V00  <-- THIS SHOULD CHANGE DYNAMICALLY   FOR EVERY RUN.             
                                                             
-COMPANY   JOURNAL-DATE   ACCOUNT-NUMBER   POST-MONTH   STATE
0 XX          030812         40956073          03        93 
  73          032612         30035093          03        93 


is this a possible requirement..?..Please let me know if i am not clear with my explanation.

Thanks in advance..
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Wed Jun 06, 2012 7:02 pm
Reply with quote

Your FIRST problem is terminology.
Quote:
step1 will produce a gdg version ex: MY.GDG.G0140V00.
is wrong -- that is a GENERATION, not a VERSION. They both exist for a GDG, but are used in very different ways and you are DEFINITELY using the terminology incorrectly. And what you are looking at is a data set name, anyway -- a generation of a GDG data set, but still a data set name.

Have you opened an issue with the vendor? They may have code that would provide what you want. If not, I'm not 100% sure it can (easily) be done in Easytrieve, although it is possible to retrieve data set name in COBOL (for example) by reading system control blocks.
Back to top
View user's profile Send private message
venugopal404

New User


Joined: 14 Dec 2010
Posts: 13
Location: hyderabad

PostPosted: Wed Jun 06, 2012 7:15 pm
Reply with quote

Robert,

Thanks for correcting my terminology..:-)

I'm a bit confused by the term "vendor".you mean the mainframe ADMINISTARTION team who takes care of the Installation of all the software stuff into machines..? icon_smile.gif
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Wed Jun 06, 2012 7:19 pm
Reply with quote

Hello,

The term vendor in your case means Computer Associates - the vendor of Easytrieve.

If you open an issue with CA Support, they can tell you if what you want is available in Easytrieve.

If your local support group has extensive knowledge of Easytrieve, they may also know if this can be done.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Wed Jun 06, 2012 7:30 pm
Reply with quote

If your site is licensed for Easytrieve, then you can open issues with the vendor Computer Associates. You may have to register on their support site, but once that is done then you have access to the product documentation, along with all sorts of questions and answers about the product -- and can open a problem ticket to find out if what you want is even possible in Easytrieve.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Wed Jun 06, 2012 7:37 pm
Reply with quote

[PREACHING ON]


you use assembler when you wish to surmount a technical problem

you use COBOL/PL1 when you wish to surmount a data-manipulation problem

you use JobControlLanguage when you wish to surmount a data flow problem.

knowing the dsn or in the case of gdg's knowing the absolute name,
can be easily accomplished without the use of programming.

set-up a proc called GCGDG (Get Current GDG Name) (this is easy to sell to the pc crowd!)
with following symbolics:
  • GDG base name
  • return value of function GCGDG (Sort Output DSN)


PROC comprises of:

STEP0010 IDCAMS with the dsn to a dd statement populated by the GDG base name symbolics
(prints Associations)
output is temporary file (&&)

STEP0020 SORT
input is temporary file from step0010
output is dsn (Sort Output DSN symbolics) with 1 record containing PARSED full name of current generation

ENDPROC



[GOODBYE]
Back to top
View user's profile Send private message
venugopal404

New User


Joined: 14 Dec 2010
Posts: 13
Location: hyderabad

PostPosted: Wed Jun 06, 2012 8:01 pm
Reply with quote

Hi Dick,

Thanks for your response..

below is the piece of jcl which i could make it out from you post.
Code:

//STEP1   EXEC PGM=IDCAMS                                         
//INPTFILE DD DSN=MY.GDG,   <--  NAME OF GDG BASE                 
//            DISP=SHR                                           
//OUTPFILE DD DSN=&&TEMP,                                         
//            DISP=(NEW,PASS,),DCB=(RECFM=FB,LRECL=687,BLKSIZE=0),
//            DATACLAS=MB050E,UNIT=SYSDA                         
//SYSOUT   DD SYSOUT=*                                           
//SYSPRINT DD SYSOUT=*                                           
//SYSIN    DD *                                                   
   REPRO INFILE(INPTFILE) OUTFILE (OUTPFILE)                     
//*                                                               
//STEP2 EXEC PGM=SORT                                             
//SORTIN DD DSN=&&TEMP,DISP=SHR                                   
//SORTOUT DD *                                                   
//SYSPRINT DD SYSOUT=*                                           
//SYSOUT DD SYSOUT=*                                             
//SYSIN DD *                                                     
  SORT FIELDS=COPY                                               


Please correct me if im wrong..

The job is still running..that's the reason for not posting the output what i got..
Back to top
View user's profile Send private message
Bill Woodger

Moderator Emeritus


Joined: 09 Mar 2011
Posts: 7309
Location: Inside the Matrix

PostPosted: Wed Jun 06, 2012 8:05 pm
Reply with quote

How about LISTCAT instead of REPRO? How would copying the file (twice) get you anywhere?
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Wed Jun 06, 2012 8:06 pm
Reply with quote

1. I would cancel the job. 36_11_6.gif
2. I said print the gdg associations (LISTCAT(ddname) ASSOC)
3. look at how the output is constructed
and determine how to include the correct line...
Back to top
View user's profile Send private message
venugopal404

New User


Joined: 14 Dec 2010
Posts: 13
Location: hyderabad

PostPosted: Wed Jun 06, 2012 9:05 pm
Reply with quote

Hi Dick..

Code:

//BACKUP   EXEC PGM=IDCAMS,COND=(0,NE)                               
//***************************************************************** 
//*                                                                 
//SYSOUT   DD SYSOUT=*                                               
//SYSPRINT DD SYSOUT=*                                               
//SYSIN    DD *                                                     
----+----1----+----2----+----3----+----4----+----5----+----6----+----
  LISTCAT ENTRIES (MY.GDG) ASSOC                                     
***ERROR  - DSS5650E - ASSOC IS NOT VALID FOR THIS COMMAND           
                           


'ASSOC ' is not a valid command is the error message which i got when cretaed the jcl as above..
please correct my syntax..
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Wed Jun 06, 2012 9:37 pm
Reply with quote

sigh!

i intended to convey an idea,
not do all the necessary coding for a particular function.

Look here for GDG and FILE keywords of the Listcat Command
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 -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts isfline didnt work in rexx at z/OS ve... CLIST & REXX 7
No new posts Need help on formatting a report DFSORT/ICETOOL 14
No new posts Creating Report using SORT DFSORT/ICETOOL 7
No new posts How to copy the -1 version of a membe... TSO/ISPF 4
No new posts Ca7 long running jobs report All Other Mainframe Topics 1
Search our Forums:

Back to Top