I don't do windoze, but on Linux using environment variables for files and lists of files is bog standard. Also, any *ix system has shell redirection for stderr, stdin and stdout using, e.g., <, >>, |.
-- Shmuel (Seymour J.) Metz http://mason.gmu.edu/~smetz3 ________________________________________ From: IBM Mainframe Discussion List [[email protected]] on behalf of Charles Mills [[email protected]] Sent: Friday, January 7, 2022 2:14 PM To: [email protected] Subject: Re: ... Re: Top 8 Reasons for using Python instead of REXX for z/OS You are right! Environment variables may be used to provide file indirection (and a lot more). I know almost enough Windows and Linux to be dangerous. I guess it would be fair to say that on z/OS indirect dataset names are very much the convention, and initially were the only supported way of doing things. On Linux and Windows there is no generally accepted convention for file indirection -- how's that? Charles -----Original Message----- From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf Of Bernd Oppolzer Sent: Friday, January 7, 2022 10:53 AM To: [email protected] Subject: Re: ... Re: Top 8 Reasons for using Python instead of REXX for z/OS Am 07.01.2022 um 19:36 schrieb Charles Mills: > FWIW yes, I go back to > > A little bit of CP/67 and OS/360 on a 360/67 in 1967 > Hardcore DOS/360 on 360/40s and /50s starting in 1968 (My first paid > software job.) > Hardcore OS/360 starting around 1972 or so. No SVC 99! > > And I disagree. Variables and file handles are not the same as DD names at > all. I can hard-code a z/OS program to copy 'MYFILE1' to 'MYFILE2'. It can > then copy any dataset to any other dataset (with many limitations, but you > get the idea). > > There is no directly equivalent function in Windows or Linux. I cannot code > arbitrary internal names (in variables or otherwise) and then map them to > real external names at run time. (AFAIK -- correct me if I am wrong. Yes, > stdin and stdout come close.) when I ported Stanford Pascal to WIN and Unix, I used environment variables to do this. IIRC, Pascal on PC/RT and RS/6000 (on AIX) did the same. For example: SET DD_OUTFILE=c:\temp\real_filename.out PRUN PASPROG and in the Pascal program: program PASPROG (OUTFILE, ...); var OUTFILE: TEXT; begin rewrite (OUTFILE); ... if there is no such env-variable, the external file name evaluates to the internal file name. SET DD_OUTFILE=*stdout* is valid, too. this works exactly the same way, no matter if on z/OS, z/VM, Unix, Windows, ... of course, on z/OS etc., you use JCL on z/VM FILEDEF Kind regards Bernd ---------------------------------------------------------------------- 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 ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
