I can do dynamic DD names in z/OS COBOL using a trick*, but that trick doesn't 
work in MF COBOL. There's no documented way to do a dynamic DD name**. Dynamic 
*file names* yes, but not DD names.

But dynamic file names are native files (e.g. C:\Data\Catalog\File.DAT) not 
catalogged MVS data set names. And a REXX exec can determine allocated MVS data 
set names, but not the associated native file name!


(I think the real question is why doesn't the COBOL language allow for logical 
files names (what you ASSIGN to) that aren't known at compile time?)


* passing the FD name to a nested program that zaps the DD name in the DCB

** A MF COBOL program can get access to its version of a DCB but that structure 
doesn't include the DD name



-----Original Message-----
From: IBM Mainframe Discussion List <[email protected]> On Behalf Of 
Steve Thompson
Sent: Tuesday, August 15, 2023 3:02 PM
To: [email protected]
Subject: Re: How can a REXX data stack pass information from a program?

Ok, what I said won't work.

Whose COBOL is in use? Is it MF COBOL? Does it support dynamic
"DD" changes via the ASSIGN? If that is the case, then passing
the DD name to the COBOL program would allow it to write to that
DD the data the caller is asking for.

Steve Thompson

On 8/15/2023 3:54 PM, Schmitt, Michael wrote:
> Micro Focus ESMVS/TSO Version 7.0.000
>

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN



----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to