You're on your own for z/OS-specific python scripts.  Mr. Google will let you 
see many python examples out on the net, but none I suspect oriented on z/OS 
facilities.

As for JCL, I use IBM's batch utility to run awk scripts, I don't know of 
python will work in the same way due to the difference between the open() and 
fopen() library routines in the IBM C library.  The awk command uses fopen() 
which allows DD's to be used as files, many other IBM Unix commands use open() 
which does NOT allow DD's to be used as files.  I do not know what the IBM or 
Rocket python implementation is using, as I do not have it here to test (we are 
at 2.3 here).

The fopen() vs open() differences may well disappear with the announced move to 
"full dataset access" for z/OS Unix services, but we don't have a delivery date 
for that functionality that I have seen.

Here is an example awk JCL I have used successfully:

//**********************************************************************
//* INVOKE AWK SCRIPT 
//**********************************************************************
// EXPORT SYMLIST=*
//RUNAWK   EXEC PGM=BPXBATCH,                                           
// PARMDD=PARMIN                                                        
//STDOUT   DD  DISP=(NEW,CATLG,CATLG),                                  
//             DSN=&SYSUID..AWK.OUTPUT.FILE,                                   
//             UNIT=SYSDA,SPACE=(CYL,(050,050),RLSE),                    
//             DSORG=PS,RECFM=VA,LRECL=516,BLKSIZE=0,BUFNO=31           
//STDERR   DD  SYSOUT=*                                                 
//SCRIPT   DD  DISP=SHR,DSN=&SYSUID..TEST.AWK(TESTAWK)                  
//AWKIN    DD  DISP=SHR,DSN=&SYSUID..TEST.AWKIN,          
//             BUFNO=31                                                 
//STDENV   DD  *                                                        
_BPX_SHAREAS=MUST                                                       
_BPX_BATCH_SPAWN=YES                                                    
//STDIN    DD  DUMMY                                                    
//PARMIN   DD  *,SYMBOLS=JCLONLY                                        
PGM /bin/awk -v OUTF=//DD:STDOUT -f //DD:SCRIPT //'&SYSUID..OTHER.DATA.FILE'    
 
  //DD:AWKIN
//

Peter

-----Original Message-----
From: IBM Mainframe Discussion List <[email protected]> On Behalf Of 
Billy Ashton
Sent: Thursday, January 13, 2022 10:54 AM
To: [email protected]
Subject: Re: Ad message paradigm (Re: Ad NetRexx (Re: Ad programming features 
(Re: ... Re: Top 8 Reasons for using Python instead of REXX for z/OS

All of this sounds interesting, so if I wanted to try out some Python scripts 
to see how they stack up to Rexx, where might I find some Python source members 
along with JCL members to run them?

Thanks!
Billy

------ Original Message ------
From "Farley, Peter x23353" 
<[email protected]>
To [email protected]
Date 1/13/2022 10:49:48 AM
Subject Re: Ad message paradigm (Re: Ad NetRexx (Re: Ad programming features 
(Re: ... Re: Top 8 Reasons for using Python instead of REXX for z/OS

>It is my understanding that Java is and has been available in z/OS for a long 
>time now, but not from TSO or CLIST directly.  From REXX via SYSCALL and 
>BPXWUNIX I suspect it is possible, but not from, e.g., the TSO / ISPF command 
>line directly....
--

This message and any attachments are intended only for the use of the addressee 
and may contain information that is privileged and confidential. If the reader 
of the message is not the intended recipient or an authorized representative of 
the intended recipient, you are hereby notified that any dissemination of this 
communication is strictly prohibited. If you have received this communication 
in error, please notify us immediately by e-mail and delete the message and any 
attachments from your system.


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

Reply via email to