You /the powers of Your organization should revisit the requirement
a GDG datasetname/generation without the last qualifier is not a Dataset name any longer
it is a GDG base name
and why would You mix GDG base name with normal datasets ???
follow on
the question might be reasonable if You only had GDGs
and wanted to check for orphans
( missing gdg bases/uncataloged datasets )
something very commendable for proper storage management
but the presence of a normal dataset is puzzling/baffling
Joined: 10 May 2007 Posts: 2454 Location: Hampshire, UK
Also: a GDG dataset is not a specific type of dataset - it could be a flat (PS) dataset, a dump or whatever. Just follows a naming specification. I haven't tried it but I suppose it could be that you could catalog a dataset that is not a part of a GDG but has a dsn ending in the same format as a GDG. Must try it some time.
Joined: 06 Jun 2008 Posts: 8700 Location: Dubuque, Iowa, USA
vasanthz, I tried with IEFBR14 and got back
Code:
IEF344I RS0BR14 IEFBR14 DD0 - ALLOCATION FAILED DUE TO DATA FACILITY SYSTEM ERRO
IGD17100I UNEXPECTED CATALOG ERROR FOR DATA SET
XXXXXXX.TESTNGDG.G9876V00
RETURN CODE IS 8 REASON CODE IS 40 IGG0CLEH
which comes back as
Quote:
40 Explanation: A DEFINE GDG command was not issued prior to the DEFINE NONVSAM command with GDG entry name.
Programmer Response: Ensure that the GDG base is defined prior to defining the non-VSAM with a GDG entry name.
So it looks like the system checks and won't catalog anything with GnnnnVnn as the last level of the data set name.
Yea Ofcourse I was about to post the details... I am also multi tasking with other office work as well, just though to thank u first and then provide a detailed explainations once I reach home.
I have requirement to get the exact file names being used in a JCL and their counts .
1. At the end of all the job steps, I am planning to read the JESYSMS while the job is running and then extract all the exact filenames being used in the JOb. (Filenames could be a GDG version or Flat file both).
2.Now in the earlier job steps which use the i/p files and create the o/p datasets. I am planning to create a report file containing names of the files and their counts. However these file names will not be exact filenames. (these will not have exact GDG version numbers)
3. Now i need to compare the exact file names in Step 1 (excluding GDG version) and Step2 (which contains file names and counts) and then finally create a FINAL file with exact filename and counts.
Not sure if this sounds confusing. Please let me know.
I am getting first 71 bytes of file names correctly
Next 9 bytes of version number also properly starting position 72. But the
file counts are not coming at position 90 correctly.
"counts of what ...
do not tell me that You want to count the record of each file "
Yes we need the count of files being used in the job. However, it will be upto our discretion for which files we want to display the counts. So now we are planning to make changes to existing cobols/ezt that create that file or call ICETOOL to get the file counts. For volume intensive files, we might not want to call ICETOOL, just that we will make change to modules to have the counts displayed while creating the files itself.