Re: REXX : how to determine the member name of a DD card
With the listdsi, i only have the pdsname in the sysdsname variable ... The member name is not indicated. -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Itschak Mugzach Envoyé : jeudi 9 septembre 2010 18:02 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card I would try LISTDSI('xxx file). It might return the dsnname into SYSDSNAME which you can investigate using member=(word(translate(sysdsname,' ',()'),2) ITschak On Thu, Sep 9, 2010 at 5:35 PM, CUNY Yann yc...@externe.generali.fr wrote: Works fine ! thank you ... -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Veilleux, Jon L Envoyé : jeudi 9 septembre 2010 16:04 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card Here is some sample REXX code that will list the dataset allocated to ddname DD1 using Listalc st. /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end exit Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Veilleux, Jon L Sent: Thursday, September 09, 2010 9:28 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card Can you use ISRDDN and parse the output? Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Dana Mitchell Sent: Thursday, September 09, 2010 9:13 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card On Wed, 8 Sep 2010 10:58:14 +0200, CUNY Yann yc...@externe.generali.fr wrote: //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. Any idea ? You can use OUTTRAP function to trap the output from the 'LISTA STATUS' TSO command. Then parse through and find the DD you are interested in. Dana -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
Yann, If you use the REXX code supplied by Jon L. Veilleux below, you will be able to get the dsn and member name. At the point in his code where the IF is triggered, sysoutline.x will contain the information you seek. Simply parse sysoutline.x into 2 variables, something like parse var sysoutline.x dsn(mem) and you should have what you want. Chuck Charles Hardee CA technologies Sr Sustaining Engineer Tel: +1-952-838-1039 charles.har...@ca.com -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of CUNY Yann Sent: Friday, September 10, 2010 9:06 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card With the listdsi, i only have the pdsname in the sysdsname variable ... The member name is not indicated. -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Veilleux, Jon L Envoyé : jeudi 9 septembre 2010 16:04 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card Here is some sample REXX code that will list the dataset allocated to ddname DD1 using Listalc st. /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end exit Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
In the second part of Itschak's reply he tells you how to extract the member name from the returned sysdsname ... CUNY Yann yc...@externe.generali.fr Sent by: IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu 10/09/2010 04:05 PM Please respond to IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu To IBM-MAIN@bama.ua.edu cc Subject Re: REXX : how to determine the member name of a DD card With the listdsi, i only have the pdsname in the sysdsname variable ... The member name is not indicated. -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Itschak Mugzach Envoyé : jeudi 9 septembre 2010 18:02 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card I would try LISTDSI('xxx file). It might return the dsnname into SYSDSNAME which you can investigate using member=(word(translate(sysdsname,' ',()'),2) ITschak -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail message, including any attachments transmitted with it, is CONFIDENTIAL and may contain legally privileged information. This message is intended solely for the use of the individual or entity to whom it is addressed. If you have received this message in error, please notify us immediately and delete it from your system. Please visit our website to read the full disclaimer: http://www.euroclear.com/site/public/disclaimer -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
No, LISTDSI will not work, at least not for me. Here's my REXX (based on Jon's earlier REXX): /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end z=listdsi(DD1 FILE) say sysdsname exit I then allocated a file to my TSO session: :ALLOC FI(DD1) DA(pdsname(memname)) SHR I then ran the REXX and received two displays as expected, but not what was wanted by the OP: pdsname(memname) pdsname The first line was from the say sysoutline.x and the second line was from say sysdsname As can be seen, no member name from LISTDSI. Chuck Charles Hardee CA technologies Sr Sustaining Engineer Tel: +1-952-838-1039 charles.har...@ca.com -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Peter Nuttall Sent: Friday, September 10, 2010 9:29 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card In the second part of Itschak's reply he tells you how to extract the member name from the returned sysdsname ... CUNY Yann yc...@externe.generali.fr Sent by: IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu 10/09/2010 04:05 PM Please respond to IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu To IBM-MAIN@bama.ua.edu cc Subject Re: REXX : how to determine the member name of a DD card With the listdsi, i only have the pdsname in the sysdsname variable ... The member name is not indicated. -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Itschak Mugzach Envoyé : jeudi 9 septembre 2010 18:02 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card I would try LISTDSI('xxx file). It might return the dsnname into SYSDSNAME which you can investigate using member=(word(translate(sysdsname,' ',()'),2) ITschak -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail message, including any attachments transmitted with it, is CONFIDENTIAL and may contain legally privileged information. This message is intended solely for the use of the individual or entity to whom it is addressed. If you have received this message in error, please notify us immediately and delete it from your system. Please visit our website to read the full disclaimer: http://www.euroclear.com/site/public/disclaimer -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
Try this: Parse sysoutline.x pdsname ( memname ) Say memname -- Donald Grinsell State of Montana 406-444-2983 dgrins...@mt.gov He who returns from a journey is not the same as he who left. -- Chinese Proverb -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Hardee, Charles H Sent: Friday, 10 September 2010 09:42 To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card No, LISTDSI will not work, at least not for me. Here's my REXX (based on Jon's earlier REXX): /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end z=listdsi(DD1 FILE) say sysdsname exit I then allocated a file to my TSO session: :ALLOC FI(DD1) DA(pdsname(memname)) SHR I then ran the REXX and received two displays as expected, but not what was wanted by the OP: pdsname(memname) pdsname The first line was from the say sysoutline.x and the second line was from say sysdsname As can be seen, no member name from LISTDSI. Chuck Charles Hardee CA technologies Sr Sustaining Engineer Tel: +1-952-838-1039 charles.har...@ca.com -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Peter Nuttall Sent: Friday, September 10, 2010 9:29 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card In the second part of Itschak's reply he tells you how to extract the member name from the returned sysdsname ... CUNY Yann yc...@externe.generali.fr Sent by: IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu 10/09/2010 04:05 PM Please respond to IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu To IBM-MAIN@bama.ua.edu cc Subject Re: REXX : how to determine the member name of a DD card With the listdsi, i only have the pdsname in the sysdsname variable ... The member name is not indicated. -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Itschak Mugzach Envoyé : jeudi 9 septembre 2010 18:02 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card I would try LISTDSI('xxx file). It might return the dsnname into SYSDSNAME which you can investigate using member=(word(translate(sysdsname,' ',()'),2) ITschak -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail message, including any attachments transmitted with it, is CONFIDENTIAL and may contain legally privileged information. This message is intended solely for the use of the individual or entity to whom it is addressed. If you have received this message in error, please notify us immediately and delete it from your system. Please visit our website to read the full disclaimer: http://www.euroclear.com/site/public/disclaimer -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
That should have been: Parse var sysoutline.x pdsname ( memname ) Regards. -- Donald Grinsell State of Montana 406-444-2983 dgrins...@mt.gov The limits of my language are the limits of my world. -- Ludwig Wittgenstein -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Grinsell, Don Sent: Friday, 10 September 2010 10:00 To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card Try this: Parse sysoutline.x pdsname ( memname ) Say memname -- Donald Grinsell State of Montana 406-444-2983 dgrins...@mt.gov He who returns from a journey is not the same as he who left. -- Chinese Proverb -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Hardee, Charles H Sent: Friday, 10 September 2010 09:42 To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card No, LISTDSI will not work, at least not for me. Here's my REXX (based on Jon's earlier REXX): /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end z=listdsi(DD1 FILE) say sysdsname exit I then allocated a file to my TSO session: :ALLOC FI(DD1) DA(pdsname(memname)) SHR I then ran the REXX and received two displays as expected, but not what was wanted by the OP: pdsname(memname) pdsname The first line was from the say sysoutline.x and the second line was from say sysdsname As can be seen, no member name from LISTDSI. Chuck Charles Hardee CA technologies Sr Sustaining Engineer Tel: +1-952-838-1039 charles.har...@ca.com -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Peter Nuttall Sent: Friday, September 10, 2010 9:29 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card In the second part of Itschak's reply he tells you how to extract the member name from the returned sysdsname ... CUNY Yann yc...@externe.generali.fr Sent by: IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu 10/09/2010 04:05 PM Please respond to IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu To IBM-MAIN@bama.ua.edu cc Subject Re: REXX : how to determine the member name of a DD card With the listdsi, i only have the pdsname in the sysdsname variable ... The member name is not indicated. -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Itschak Mugzach Envoyé : jeudi 9 septembre 2010 18:02 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card I would try LISTDSI('xxx file). It might return the dsnname into SYSDSNAME which you can investigate using member=(word(translate(sysdsname,' ',()'),2) ITschak -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail message, including any attachments transmitted with it, is CONFIDENTIAL and may contain legally privileged information. This message is intended solely for the use of the individual or entity to whom it is addressed. If you have received this message in error, please notify us immediately and delete it from your system. Please visit our website to read the full disclaimer: http://www.euroclear.com/site/public/disclaimer -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
You are right. My example was just showing how to get the full filename. I (mistakenly) thought that anyone with a little bit of REXX knowledge would be able to parse out the membername from the full name. Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Hardee, Charles H Sent: Friday, September 10, 2010 11:42 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card No, LISTDSI will not work, at least not for me. Here's my REXX (based on Jon's earlier REXX): /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end z=listdsi(DD1 FILE) say sysdsname exit I then allocated a file to my TSO session: :ALLOC FI(DD1) DA(pdsname(memname)) SHR I then ran the REXX and received two displays as expected, but not what was wanted by the OP: pdsname(memname) pdsname The first line was from the say sysoutline.x and the second line was from say sysdsname As can be seen, no member name from LISTDSI. Chuck Charles Hardee CA technologies Sr Sustaining Engineer Tel: +1-952-838-1039 charles.har...@ca.com -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Peter Nuttall Sent: Friday, September 10, 2010 9:29 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card In the second part of Itschak's reply he tells you how to extract the member name from the returned sysdsname ... CUNY Yann yc...@externe.generali.fr Sent by: IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu 10/09/2010 04:05 PM Please respond to IBM Mainframe Discussion List IBM-MAIN@bama.ua.edu To IBM-MAIN@bama.ua.edu cc Subject Re: REXX : how to determine the member name of a DD card With the listdsi, i only have the pdsname in the sysdsname variable ... The member name is not indicated. -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Itschak Mugzach Envoyé : jeudi 9 septembre 2010 18:02 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card I would try LISTDSI('xxx file). It might return the dsnname into SYSDSNAME which you can investigate using member=(word(translate(sysdsname,' ',()'),2) ITschak -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail message, including any attachments transmitted with it, is CONFIDENTIAL and may contain legally privileged information. This message is intended solely for the use of the individual or entity to whom it is addressed. If you have received this message in error, please notify us immediately and delete it from your system. Please visit our website to read the full disclaimer: http://www.euroclear.com/site/public/disclaimer -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
On Wed, 8 Sep 2010 10:58:14 +0200, CUNY Yann yc...@externe.generali.fr wrote: //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. Any idea ? You can use OUTTRAP function to trap the output from the 'LISTA STATUS' TSO command. Then parse through and find the DD you are interested in. Dana -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
Can you use ISRDDN and parse the output? Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Dana Mitchell Sent: Thursday, September 09, 2010 9:13 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card On Wed, 8 Sep 2010 10:58:14 +0200, CUNY Yann yc...@externe.generali.fr wrote: //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. Any idea ? You can use OUTTRAP function to trap the output from the 'LISTA STATUS' TSO command. Then parse through and find the DD you are interested in. Dana -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
Here is some sample REXX code that will list the dataset allocated to ddname DD1 using Listalc st. /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end exit Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Veilleux, Jon L Sent: Thursday, September 09, 2010 9:28 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card Can you use ISRDDN and parse the output? Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Dana Mitchell Sent: Thursday, September 09, 2010 9:13 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card On Wed, 8 Sep 2010 10:58:14 +0200, CUNY Yann yc...@externe.generali.fr wrote: //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. Any idea ? You can use OUTTRAP function to trap the output from the 'LISTA STATUS' TSO command. Then parse through and find the DD you are interested in. Dana -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
Works fine ! thank you ... -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Veilleux, Jon L Envoyé : jeudi 9 septembre 2010 16:04 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card Here is some sample REXX code that will list the dataset allocated to ddname DD1 using Listalc st. /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end exit Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Veilleux, Jon L Sent: Thursday, September 09, 2010 9:28 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card Can you use ISRDDN and parse the output? Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Dana Mitchell Sent: Thursday, September 09, 2010 9:13 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card On Wed, 8 Sep 2010 10:58:14 +0200, CUNY Yann yc...@externe.generali.fr wrote: //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. Any idea ? You can use OUTTRAP function to trap the output from the 'LISTA STATUS' TSO command. Then parse through and find the DD you are interested in. Dana -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
I would try LISTDSI('xxx file). It might return the dsnname into SYSDSNAME which you can investigate using member=(word(translate(sysdsname,' ',()'),2) ITschak On Thu, Sep 9, 2010 at 5:35 PM, CUNY Yann yc...@externe.generali.fr wrote: Works fine ! thank you ... -Message d'origine- De : IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] De la part de Veilleux, Jon L Envoyé : jeudi 9 septembre 2010 16:04 À : IBM-MAIN@bama.ua.edu Objet : Re: REXX : how to determine the member name of a DD card Here is some sample REXX code that will list the dataset allocated to ddname DD1 using Listalc st. /* rexx */ Z=OUTTRAP(SYSOUTLINE.,'*',NOCONCAT) ADDRESS TSO INDEX=' ' LISTALC STATUS Z=OUTTRAP(OFF) I=1 DO i=1 to SYSOUTLINE.0 test=word(sysoutline.i,1) if test='DD1' then do x=i-1 say sysoutline.x i=sysoutline.0 end end exit Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Veilleux, Jon L Sent: Thursday, September 09, 2010 9:28 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card Can you use ISRDDN and parse the output? Jon L. Veilleux veilleu...@aetna.com (860) 636-9179 -Original Message- From: IBM Mainframe Discussion List [mailto:ibm-m...@bama.ua.edu] On Behalf Of Dana Mitchell Sent: Thursday, September 09, 2010 9:13 AM To: IBM-MAIN@bama.ua.edu Subject: Re: REXX : how to determine the member name of a DD card On Wed, 8 Sep 2010 10:58:14 +0200, CUNY Yann yc...@externe.generali.fr wrote: //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. Any idea ? You can use OUTTRAP function to trap the output from the 'LISTA STATUS' TSO command. Then parse through and find the DD you are interested in. Dana -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
REXX : how to determine the member name of a DD card
Hi all ! I have this JCL : //STEP11 EXEC PGM=IKJEFT01,REGION=0M //SYSTSIN DD * PROFILE NOPREF TEST15 /* //SYSTSPRT DD SYSOUT=* //SYSEXEC DD DSN=P3CUN.YANN.REXX,DISP=SHR //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. I don't want to add a paramèter. And I don't want to make an execio on another dd card. Any idea ? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: REXX : how to determine the member name of a DD card
Hi! You can go from TCB to TIOT and then from TIOT to JFCB. In TIOT there is a table of all DD statements of the job, In each table entry there is pointer to approp. JFCB. In JFCB there are entries( one on more) for all DSN-s on this DD statement (1 where concatenation occurs), possibly. with member name (when dsn has form dsnname(membername)). /*===REXX=2010/09/02===KF===*/ /*---*/ /* Build stem zbiory_joba remembering names all DD statem. of */ /* job and for each dd statement DDNAME and name(s)(DSN) data */ /* sets (possibly with membername). */ /* Names - where on DD there are concatenated data sets. */ /*---*/ buld_jobs_files: /*---*/ /* zbiory_joba.nr_dd.ddn- names of following jobs joba.(8b) */ /* zbiory_joba.nr_dd.ile-- number of concatenated data sets */ /* on this DD statement. */ /* zbiory_joba.nr_dd.nr_dsn.dsn-- dsn-s on DD number */ /* nr_dd. */ /* zbiory_joba.nr_dd.nr_dsn.mem-- member (or 8 spaces) for */ /* DSN number nr_dd. */ /* (DSN=dsnname(membername) */ /* */ /*---*/ /* TCB - task control block */ /* TIOT - task input/output table */ /* JFCB - Job File Control Block */ /*---*/ /* TCB+12 ---TIOT */ /* TIOT+24 first DD entry */ /* +4(8 bytes=DDNAME) */ /* +12(3 bytes -swa coded JFCB address) */ /* | */ /* | */ /* V */ /* JFCB (44 bytes=DSN) */ /* JFCB+44 (8bytes=membername or spaces) */ /*===*/ /* start of current TCB - address 540 */ tcbadr=C2D(STORAGE(D2X(540),4)) /* from TCB to TIOT */ adrtioa=C2D(STORAGE(D2X(tcbadr+12),4)) /**/ /* In TIOA table of all DD entries */ /* current jobstep. */ /**/ /* skip first 24 bytes (not interesting for us) */ adrtioa=adrtioa+24 /* address of first DD segment */ dd_count=0 dsn_count=0 do forever /* do until entry length 0 */ entrylen=C2D(STORAGE(D2X(adrtioa),1)) /* len of current entry */ /* on 1 byte! */ if entrylen=0 then leave adrdd=adrtioa+4 ddname=STORAGE(D2X(adrdd),8) if ddnamethen do /* not concatenated or first in conc. */ dd_count=dd_count+1 zbiory_joba.dd_count.ddn=ddname dsn_count=1 zbiory_joba.dd_count.ile=1 end else do /* DD = spaces - concatenation */ dsn_count=dsn_count+1 /* count conc. data sets */ zbiory_joba.dd_count.ile=dsn_count end /* from TIOT entry to JFCB */ /* JFCB address on 3 bytes! (and sva coded!) */ adrjfcb=C2D(STORAGE(D2X(adrtioa+12),3)) /* add left zreoes 8 digits (4 bytes)*/ if LENGTH(adrjfcb)=2 then adrjfcb='00'||adrjfcb if LENGTH(adrjfcb)=3 then adrjfcb='0'||adrjfcb else if LENGTH(adrjfcb)=4 then adrjfcb=''||adrjfcb else if LENGTH(adrjfcb)=5 then adrjfcb='000'||adrjfcb else if LENGTH(adrjfcb)=6 then adrjfcb='00'||adrjfcb else if LENGTH(adrjfcb)=7 then adrjfcb='0'||adrjfcb /* uncode JFCB address */ if adrjfcb//16 15 then adrjfb=adrjfcb+16 else do NUMERIC DIGITS 10 /* bo max. to 7FFF */ tcb=C2D(STORAGE(D2X(540),4)) jscb=C2D(STORAGE(D2X(tcb+180),4)) qmpl=C2D(STORAGE(D2X(jscb+244),4)) qmat=C2D(STORAGE(D2X(qmpl+24),4)) do forever if adrjfcb65536 then do qmat=C2D(STORAGE(D2X(qmat+12),4)) adrjfcb=adrjfcb-65536; end else do adrjfcb=C2D(STORAGE(D2X(qmat+adrjfcb+1),4))+16 leave end end end /* now adrjfcb is really JFCB address */ /* DSN- (jfcb+0)and member (or 8 spaces)-(jfcb+44) */ dsnname=STRIP(STORAGE(D2X(adrjfcb),44)) member=STRIP(STORAGE(D2X(adrjfcb+44),8)) zbiory_joba.dd_count.dsn_count.dsn=dsnname /* nazwa membra (o ile podano dsn=filename(membername)),lub 8 spacji*/ zbiory_joba.dd_count.dsn_count.mem=member /* next dd entry in TIOT */ adrtioa=adrtioa+entrylen /* next dd entry */ end /* forever len0 ( TIOT ) */ /* return */ novalue: say 'Niezainicjowana zmienna w linii 'SIGL exit 22 failure: say 'Blad komendy w linii 'SIGL exit 33 /* Koniec zrodla */ regards Karol Filipowicz Poland 2010/9/8 CUNY Yann yc...@externe.generali.fr Hi all ! I have this JCL : //STEP11 EXEC PGM=IKJEFT01,REGION=0M //SYSTSIN DD * PROFILE NOPREF TEST15 /* //SYSTSPRT DD SYSOUT=* //SYSEXEC DD DSN=P3CUN.YANN.REXX,DISP=SHR //IN DD DSN=P3CUN.YANN.JCL(TEST14),DISP=SHR I need, in my rexx, to retrieve the member name of the DD CARD IN. With the LISTDSI, I just have the pds name. I don't want to add a paramèter. And I don't want to make an execio on another dd card. Any idea ? -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html