Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
On Feb 11, 2016, at 8:50 AM, R.S. wrote: DD name points to dataset. A program can or cannot read all the members. Examples: IEBPTPCH - can print all the members And PUNCH :) IEBCOPY - can copy all the members -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
On Feb 11, 2016, at 8:34 AM, John McKown wrote: On Thu, Feb 11, 2016 at 8:05 AM, Ed Gouldwrote: John, There *MAY* be a way, albeit adding an extra step to do so. But I don't think that is what he wanted. I think so too. I already _have_ a way to do something like what the OP wanted. And it even includes all my options, except for the changing & naming of the members involved. Basically, I can _easily_(?) unload the members from any, or multiple, PDS library to a sequential DD. But I do an "evil" thing. I use a UNIX step which run programs from Dovetailed Technologies. --SNIP--- I admit your way is one way. I was thinking the offload utility off of CBTAPE.ORG (not sure which member off the top of my head) With one step it unloads the PDS to a sequential file (with or without ./ add statements) Both of our ways need a OEM utility. I prefer mine as it does need any licensing (not that COZ stuff is OK but at least offload you get the source and can debug it yourself), not that its needs it (I have run from the same source for 20+ years granted PDSE's might not work but I avoid PDSE's like the plague). Ed -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
On Thu, Feb 11, 2016 at 8:05 AM, Ed Gouldwrote: > John, > > There *MAY* be a way, albeit adding an extra step to do so. > But I don't think that is what he wanted. > I think so too. I already _have_ a way to do something like what the OP wanted. And it even includes all my options, except for the changing & naming of the members involved. Basically, I can _easily_(?) unload the members from any, or multiple, PDS library to a sequential DD. But I do an "evil" thing. I use a UNIX step which run programs from Dovetailed Technologies. //UNLOAD EXEC PROC=COZBATCH //STDOUT DD SYSOUT=* //STDERR DD SYSOUT=* //STDIN DD * # # copy contents of all members whose # names start with A to # the DD OUTPUT pdsdir some.pds |\ egrep '^A' |\ while read pdsmem;do fromdsn "//some.pds($pdsmem)" done |\ todsn "//DD:OUTPUT" # # copy all members from dsn=pds2 whose names end with a B # and from dsn=pds3 whose name contain an E to # the DD OUTPUT2 { pdsdir pds2 |\ egrep 'B$' |\ while read pdsmem;do fromdsn "//pds2($pdsmem)";done pdsdir pds3 |\ egrep 'E' |\ while read pdsmem;do fromdsn "//pds3($pdsmem)";done } | todsn "//DD:OUTPUT2" /* //OUTPUT DD SPACE=(CYL,(20,10),RLSE), // DCB=(some.pds,DSORG=PS), // DISP=(,PASS) //OUTPUT2 DD SPACE=(CYL,(100,10),RLSE), // RECFM=?,DSORG=PS,LRECL=?,BLKSIZE=0 // DISP=(,PASS) //* //* MORE STEPS > > Ed > > -- The man has the intellect of a lobotomized turtle. Maranatha! <>< John McKown -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
DD name points to dataset. A program can or cannot read all the members. Examples: IEBPTPCH - can print all the members IEBCOPY - can copy all the members -- Radoslaw Skorupka Lodz, Poland --- Treść tej wiadomości może zawierać informacje prawnie chronione Banku przeznaczone wyłącznie do użytku służbowego adresata. Odbiorcą może być jedynie jej adresat z wyłączeniem dostępu osób trzecich. Jeżeli nie jesteś adresatem niniejszej wiadomości lub pracownikiem upoważnionym do jej przekazania adresatowi, informujemy, że jej rozpowszechnianie, kopiowanie, rozprowadzanie lub inne działanie o podobnym charakterze jest prawnie zabronione i może być karalne. Jeżeli otrzymałeś tę wiadomość omyłkowo, prosimy niezwłocznie zawiadomić nadawcę wysyłając odpowiedź oraz trwale usunąć tę wiadomość włączając w to wszelkie jej kopie wydrukowane lub zapisane na dysku. This e-mail may contain legally privileged information of the Bank and is intended solely for business use of the addressee. This e-mail may only be received by the addressee and may not be disclosed to any third parties. If you are not the intended addressee of this e-mail or the employee authorized to forward it to the addressee, be advised that any dissemination, copying, distribution or any other similar activity is legally prohibited and may be punishable. If you received this e-mail by mistake please advise the sender immediately by using the reply facility in your e-mail software and delete permanently this e-mail including any copies of it either printed or saved to hard drive. mBank S.A. z siedzibą w Warszawie, ul. Senatorska 18, 00-950 Warszawa, www.mBank.pl, e-mail: kont...@mbank.pl Sąd Rejonowy dla m. st. Warszawy XII Wydział Gospodarczy Krajowego Rejestru Sądowego, nr rejestru przedsiębiorców KRS 025237, NIP: 526-021-50-88. Według stanu na dzień 01.01.2016 r. kapitał zakładowy mBanku S.A. (w całości wpłacony) wynosi 168.955.696 złotych. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
Bob, If your intention is to read entire PDS (all the members) and write them to a sequential file then you can use good old program IEBPTPCH to print the members. http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/DGT2U170/10.0? Other utilities like IBMs File Manager have much more robust capabilities in terms of member selection with wild card functionality and you can even perform updates ( change 'string 1' to 'string 2' ) (search for FCH in the manual for this) //*** //* COPY ALL THE PDS MEMBERS THAT HAS "D" ANYWHERE IN THE NAME * //*** //STEP0100 EXEC PGM=FILEMGR //SYSPRINT DD SYSOUT=* //PDS DD DISP=SHR,DSN=KOLUSU.PLAY.PDS //DDOUTDD SYSOUT=* //SYSINDD * $$FILEM DSC INPUT=PDS,MEMBER=*D* //* http://publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/fmnu1m00/2.3.4.11? Thanks, Kolusu From: "Lester, Bob" <bles...@ofiglobal.com> To: IBM-MAIN@LISTSERV.UA.EDU Date: 02/10/2016 05:08 PM Subject: DD DSN=xx.xx.xx reads all members if it's a PDS? Sent by:IBM Mainframe Discussion List <IBM-MAIN@LISTSERV.UA.EDU> Hi Folks, OK, it's only Wednesday, but Wouldn't it be nice if you could code: //SOMEDD DD DSN=SOME.PDS.DSN,DISP=SHR ...and it would read all the members in order? Maybe even any order you specify? Maybe (ducking!) like it works with GDGs when you specify the base only? Am I crazy before Friday? Thanks! BobL This e-mail transmission may contain information that is proprietary, privileged and/or confidential and is intended exclusively for the person(s) to whom it is addressed. Any use, copying, retention or disclosure by any person other than the intended recipient or the intended recipient's designees is strictly prohibited. If you are not the intended recipient or their designee, please notify the sender immediately by return e-mail and delete all copies. OppenheimerFunds may, at its sole discretion, monitor, review, retain and/or disclose the content of all email communications. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
John, There *MAY* be a way, albeit adding an extra step to do so. But I don't think that is what he wanted. Ed On Feb 11, 2016, at 7:34 AM, John McKown wrote: On Wed, Feb 10, 2016 at 6:08 PM, Lester, Bobwrote: Hi Folks, OK, it's only Wednesday, but Wouldn't it be nice if you could code: //SOMEDD DD DSN=SOME.PDS.DSN,DISP=SHR ...and it would read all the members in order? Maybe even any order you specify? Maybe (ducking!) like it works with GDGs when you specify the base only? Am I crazy before Friday? Thanks! BobL Well, most of the time when a DD is coded like that, it means that the program involved is most likely going to be using BPAM to process separate members (like COBOL with copybooks or HLASM with COPY or macros). So, unlike GDGs, the access method would need to have special coding. In particular, when doing an OPEN with a DCB which has DSORG=PO, then the "system" could not do your processing. So, the BSAM/QSAM access method would need to do something like "if I open a DCB with DSORG=PS, and the DSN is actually PO, then set up to read each member in order". But wait! There is a problem There is a _lot_ of code which already does an OPEN of a PO data set with a DCB with a DSORG=PS in it. In fact, that is a _documented_ way to read the directory of the PDS as if it were a data sets. And this process even works with PDSE libraries. Well, I think this should explain why what you are desiring is actually impossible. It would destroy existing code, horribly. Perhaps a new JCL format? //SOMEDD DD DSN=SOME.PDS.DSN(*),DISP=SHR which could lead to other "wildcards" such as SOME.PDS.DSN(A*) to get everything which starts with A. Or SOME.PDS.DSN(*A) for all member which _end_ in A. Or SOME.PDS.DSN(*A*) for members which have an "A" in the anywhere. Now we're cooking with fire! But wait! There's more! How about making the "pattern" be a "glob" ( https://en.wikipedia.org/wiki/Glob_(programming) ) for even better pattern matching. OK, we're using a gas range with an hibachi. And lastly, for a plasma flame crowd, let's go all the way and use EREs! (Extended Regular Expressions). Now all we need to determine is _when_ to generate the list of member names? I would suggest at OPEN time. The next thing that somebody would want is some sort of way to determine when the program started reading a new member and what the member name is that we just start (are currently) reading is. -- The man has the intellect of a lobotomized turtle. Maranatha! <>< John McKown -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
On Wed, Feb 10, 2016 at 6:08 PM, Lester, Bobwrote: > Hi Folks, > > OK, it's only Wednesday, but > > Wouldn't it be nice if you could code: > > //SOMEDD DD DSN=SOME.PDS.DSN,DISP=SHR > > ...and it would read all the members in order? Maybe even any order > you specify? > > Maybe (ducking!) like it works with GDGs when you specify the base > only? > > Am I crazy before Friday? > > Thanks! > BobL > > Well, most of the time when a DD is coded like that, it means that the program involved is most likely going to be using BPAM to process separate members (like COBOL with copybooks or HLASM with COPY or macros). So, unlike GDGs, the access method would need to have special coding. In particular, when doing an OPEN with a DCB which has DSORG=PO, then the "system" could not do your processing. So, the BSAM/QSAM access method would need to do something like "if I open a DCB with DSORG=PS, and the DSN is actually PO, then set up to read each member in order". But wait! There is a problem There is a _lot_ of code which already does an OPEN of a PO data set with a DCB with a DSORG=PS in it. In fact, that is a _documented_ way to read the directory of the PDS as if it were a data sets. And this process even works with PDSE libraries. Well, I think this should explain why what you are desiring is actually impossible. It would destroy existing code, horribly. Perhaps a new JCL format? //SOMEDD DD DSN=SOME.PDS.DSN(*),DISP=SHR which could lead to other "wildcards" such as SOME.PDS.DSN(A*) to get everything which starts with A. Or SOME.PDS.DSN(*A) for all member which _end_ in A. Or SOME.PDS.DSN(*A*) for members which have an "A" in the anywhere. Now we're cooking with fire! But wait! There's more! How about making the "pattern" be a "glob" ( https://en.wikipedia.org/wiki/Glob_(programming) ) for even better pattern matching. OK, we're using a gas range with an hibachi. And lastly, for a plasma flame crowd, let's go all the way and use EREs! (Extended Regular Expressions). Now all we need to determine is _when_ to generate the list of member names? I would suggest at OPEN time. The next thing that somebody would want is some sort of way to determine when the program started reading a new member and what the member name is that we just start (are currently) reading is. -- The man has the intellect of a lobotomized turtle. Maranatha! <>< John McKown -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
Since the DD statement doesn't have enough options yet, one could always add a few more.:) And to be really useful, there should be an exit or some other means to convey the directory information for each member back to the program, and if specifying order of members, some way to tell the z/OS to read the members in the most efficient order when order was not an issue for the program. I always found it extremely annoying that the only standard access interfaces IBM provided to allow a program to access directory information and all members of a PDS was a terribly cumbersome and inefficient approach -- no good ways to exploit full-track or multi-track I/O on devices where that offered significant performance advantages. Joel C. Ewing On 02/10/2016 06:44 PM, Bill Woodger wrote: > But you need that (and just a little bit more) to read the directory blocks. > Wouldn't that become confusing? > > Having said that, something a little less... wordy. than Library Management > Services would be handy to read members from a library in, say, a COBOL > program. > > On Thursday, 11 February 2016 00:08:49 UTC, Lester, Bob wrote: >> Hi Folks, >> >> OK, it's only Wednesday, but >> >> Wouldn't it be nice if you could code: >> >> //SOMEDD DD DSN=SOME.PDS.DSN,DISP=SHR >> >> ...and it would read all the members in order? Maybe even any order >> you specify? >> >> Maybe (ducking!) like it works with GDGs when you specify the base only? >> >> Am I crazy before Friday? >> >> Thanks! >> BobL >> > -- Joel C. Ewing,Bentonville, AR jcew...@acm.org -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
DD DSN=xx.xx.xx reads all members if it's a PDS?
But you need that (and just a little bit more) to read the directory blocks. Wouldn't that become confusing? Having said that, something a little less... wordy. than Library Management Services would be handy to read members from a library in, say, a COBOL program. On Thursday, 11 February 2016 00:08:49 UTC, Lester, Bob wrote: > Hi Folks, > > OK, it's only Wednesday, but > > Wouldn't it be nice if you could code: > > //SOMEDD DD DSN=SOME.PDS.DSN,DISP=SHR > > ...and it would read all the members in order? Maybe even any order you > specify? > > Maybe (ducking!) like it works with GDGs when you specify the base only? > > Am I crazy before Friday? > > Thanks! > BobL > -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
Re: DD DSN=xx.xx.xx reads all members if it's a PDS?
===>pds some.pds.dsn In a message dated 2/10/2016 6:08:48 P.M. Central Standard Time, bles...@ofiglobal.com writes: Wouldn't it be nice if you could code: //SOMEDD DD DSN=SOME.PDS.DSN,DISP=SHR ...and it would read all the members in order? Maybe even any order you specify? Maybe (ducking!) like it works with GDGs when you specify the base only? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN
DD DSN=xx.xx.xx reads all members if it's a PDS?
Hi Folks, OK, it's only Wednesday, but Wouldn't it be nice if you could code: //SOMEDD DD DSN=SOME.PDS.DSN,DISP=SHR ...and it would read all the members in order? Maybe even any order you specify? Maybe (ducking!) like it works with GDGs when you specify the base only? Am I crazy before Friday? Thanks! BobL This e-mail transmission may contain information that is proprietary, privileged and/or confidential and is intended exclusively for the person(s) to whom it is addressed. Any use, copying, retention or disclosure by any person other than the intended recipient or the intended recipient's designees is strictly prohibited. If you are not the intended recipient or their designee, please notify the sender immediately by return e-mail and delete all copies. OppenheimerFunds may, at its sole discretion, monitor, review, retain and/or disclose the content of all email communications. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN