Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Bill Woodger
Interestingly, a recommendation form IBM (under "DFSMSdfp: Accommodate changes in LISTCAT LEVEL output"): "Take steps to convert any programs that rely upon LISTCAT output to use the Catalog Search Interface (CSI) instead. CSI is a supported general-use programming interface for the catalog,

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Tom Marchant
On Fri, 18 Nov 2016 11:42:33 -0600, Elardus Engelbrecht wrote: >I would suggest that you ensure that the dataset is freed / un-allocated >(BPXWDYN is very useful here) after the write and before the rename. Right. If it is allocated, the rename will fail. What do you do if another address space

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Elardus Engelbrecht
Lizette Koehler wrote: >1) Identify the GDG base and what the To/From GDG Numbers are. I cannot use >Relative numbers as GDGs are always being created, so when the program starts >I want just the ones created at that time this program begins to execute. You have gotten good replies (CSI,

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Farley, Peter x23353
The example given in the first link uses calls to the POSIX setenv() function to set the value of the environment variable. LE has a non-POSIX function to do the same thing, meaning you can create a regular load module in a PDS rather than a program object in a PDSE.

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Lizette Koehler
Thank you everyone so far. Yes, I can use the BPXWDYN function for dynamic allocation. Just not REXX So it sounds like nothing native in Cobol. So my design is probably going to be Step 1 - IDCAMS ListC Step 2 - Cobol Read IDCAMS Listc and create a list of GDGs to process Using

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Phil Sidler
See if this helps you. https://mainframe.elevengestures.com/processing-a-gdg-in-any-order/ A combination of using ISGCSI00 and COBOL's dynamic allocation http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/IGY3LR50/4.2.3.1

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Bill Woodger
To access the files you will need to use "dynamic allocation". There's a couple of methods, and some search-engineing for Tom Ross COBOL Dynamic Allocation should get you some working examples. I'd LISTCAT to a data set, and read the data set in the COBOL program. Gives you a fixed point, a

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Tom Marchant
On Fri, 18 Nov 2016 07:54:06 -0700, Lizette Koehler wrote: >1) Identify the GDG base and what the To/From GDG Numbers are. I cannot use >Relative numbers as GDGs are always being created, so when the program starts I >want just the ones created at that time this program begins to execute. So it

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Burrell, Todd
I'd probably try to accomplish this by doing a LISTCAT of the GDG Base and then I would pass that into a REXX exec to parse out the GDG versions into a STEM variable. You could then generate the JCL out of the same REXX to run the COBOL program separate times for each GDG version - and you

Re: How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread John McKown
On Fri, Nov 18, 2016 at 8:54 AM, Lizette Koehler wrote: > List - > > I am a very basic Cobol programmer - openfile/read rec/write rec/close file > > What I need to understand is how to do the following > > I want to either pass a parm or a DD statement that contains a

How to tell COBOL to read a concatenation of GDGs

2016-11-18 Thread Lizette Koehler
List - I am a very basic Cobol programmer - openfile/read rec/write rec/close file What I need to understand is how to do the following I want to either pass a parm or a DD statement that contains a GDG Base //S1 EXEC PGM=X,PARM='GDGBASE' Or //S1 EXEC PGM=X //GDGBASE DD