Discussion:
curious: Uses of REXX.
(too old to reply)
John McKown
2017-04-12 13:49:13 UTC
Permalink
Raw Message
Hope this isn't so off-topic as to be offensive.

I'm just in a wondering mood today. And I'm writing a REXX application "in
my off time" (and I can be quite "off" at times). But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write
UNIX scripts in REXX?

I'm writing a "trimodal" REXX program. I am designing it to run as a normal
ISPF application; as a UNIX application under TSO OMVS (using the pt3270
interface so that it is really the aforementioned ISPF application); and as
a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to
via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have
any kind of "windowing" package for REXX, like "curses" for C.

--
"Irrigation of the land with seawater desalinated by fusion power is
ancient. It's called 'rain'." -- Michael McClary, in alt.fusion

Maranatha! <><
John McKown

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Don Hoben
2017-04-12 13:57:27 UTC
Permalink
Raw Message
Rarely use IRXJCL, heavy user of IKJEFT01. For example, generate reports, analyze job output, read RACF EXTRACT and generate RACF commands.

Don Hoben

-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of John McKown
Sent: Wednesday, April 12, 2017 9:50 AM
To: TSO-***@VM.MARIST.EDU
Subject: [TSO-REXX] curious: Uses of REXX.

Hope this isn't so off-topic as to be offensive.

I'm just in a wondering mood today. And I'm writing a REXX application "in my off time" (and I can be quite "off" at times). But I wondering if REXX on z/OS is really used much beyond ISPF macros and the occasional TSO command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write UNIX scripts in REXX?

I'm writing a "trimodal" REXX program. I am designing it to run as a normal ISPF application; as a UNIX application under TSO OMVS (using the pt3270 interface so that it is really the aforementioned ISPF application); and as a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have any kind of "windowing" package for REXX, like "curses" for C.

--
"Irrigation of the land with seawater desalinated by fusion power is ancient. It's called 'rain'." -- Michael McClary, in alt.fusion

Maranatha! <><
John McKown

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions, send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Paul Gilmartin
2017-04-12 14:05:44 UTC
Permalink
Raw Message
Post by John McKown
I'm just in a wondering mood today. And I'm writing a REXX application "in
my off time" (and I can be quite "off" at times). But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write
UNIX scripts in REXX?
I have written a trimodal Rexx EXEC using the SDSF API to fetch all
the spool data sets of a job into members of a UNIX file hierarchy.
Shortcomings
o There's no good way to select among FILEDATA(TEXT|BINARY|RECORD).
SYSLIN should be BINARY; SYSPRINT TEXT (usually); etc.
o Spool files have no CCSID attribute to reflect in file tags.
CHARS doesn't quite do it. Is there a table mapping CHARS to CCSID?

And an EXEC to fetch and umpack packages from CBTTAPE.org. TSO only
because shell or IRXJCL provides no way to reply to the RECEIVE prompt.

-- gil

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Steve Thompson
2017-04-12 14:12:54 UTC
Permalink
Raw Message
I use IKJEFT* to drive REXX to do batch oriented work. Some of it
does use ISPF library functions, many do not.

I also use OMVS commands to deal with Unix File system read/write
and scan of directories and the like, as well as the sleep
function (exists for REXX in CMS, but needed OMVS commands to
effect it in REXX for z/OS!!).

Possible future project will require this for interfacing with
Git client/server. This would be based on prior work for fetching
source via NFS out of the Unix File system. Again, lots of OMVS
type commands used from within REXX.

Regards,
Steve Thompson
Post by John McKown
Hope this isn't so off-topic as to be offensive.
I'm just in a wondering mood today. And I'm writing a REXX application "in
my off time" (and I can be quite "off" at times). But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write
UNIX scripts in REXX?
I'm writing a "trimodal" REXX program. I am designing it to run as a normal
ISPF application; as a UNIX application under TSO OMVS (using the pt3270
interface so that it is really the aforementioned ISPF application); and as
a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to
via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have
any kind of "windowing" package for REXX, like "curses" for C.
--
"Irrigation of the land with seawater desalinated by fusion power is
ancient. It's called 'rain'." -- Michael McClary, in alt.fusion
Maranatha! <><
John McKown
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Paul Gilmartin
2017-04-12 14:39:21 UTC
Permalink
Raw Message
Post by Steve Thompson
I use IKJEFT* to drive REXX to do batch oriented work. Some of it
does use ISPF library functions, many do not.
I also use OMVS commands to deal with Unix File system read/write
and scan of directories and the like, as well as the sleep
function (exists for REXX in CMS,
Sort of. It's not a Rexx facility but a host command.
Post by Steve Thompson
but needed OMVS commands to effect it in REXX for z/OS!!).
(This can be done with SYSCALL, assuming you need to optiomize
the performance of sleep.)

How much do you do with SYSCALL as opposed to UNIX utility commands?
Post by Steve Thompson
Possible future project will require this for interfacing with
Git client/server. This would be based on prior work for fetching
source via NFS out of the Unix File system. Again, lots of OMVS
type commands used from within REXX.
NFS is great!

-- gil

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Steve Thompson
2017-04-12 18:36:17 UTC
Permalink
Raw Message
<snippage>
Post by Paul Gilmartin
(This can be done with SYSCALL, assuming you need to optiomize
the performance of sleep.)
Yep, I'd forgotten the SYSCALL stuff.
Post by Paul Gilmartin
How much do you do with SYSCALL as opposed to UNIX utility commands?
In a prior position, I wrote a source fetch routine as the basis
of an SMPE command generator using SYSCALL. So it would produce
PTFs or FUNCTION...

That future project I mentioned below may have to use SYSCALL as
well.
Post by Paul Gilmartin
Post by Steve Thompson
Possible future project will require this for interfacing with
Git client/server. This would be based on prior work for fetching
source via NFS out of the Unix File system. Again, lots of OMVS
type commands used from within REXX.
NFS is great!
-- gil
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Nims,Alva John , Al
2017-04-12 14:35:11 UTC
Permalink
Raw Message
I use IKJEFT* to process several of the REXX programs I have written and in a past job, I used REXX with TSO PIPE command to process auditing function used to validate RACF UserIDs (don't ask, was a ROYAL PAIN in my backside that had to be done anywhere from once a year to 4 times a year, depending on the customer).
Currently I use REXX for:
#1. Send the input to the OMVS "dig" command and process the output for IP address lookups.
#2. Process the output from a SMP/e APPLY CHECK output to build an EXCEL (xml based) spreadsheet with links to HTML versions of the HOLDDATA of a PTF, if it has any, and the header of the PTF information.
#3. Currently crunching some external data in CSV format for Internet intrusion blocks.

Al Nims
University of Florida

-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of John McKown
Sent: Wednesday, April 12, 2017 9:50 AM
To: TSO-***@VM.MARIST.EDU
Subject: [TSO-REXX] curious: Uses of REXX.

Hope this isn't so off-topic as to be offensive.

I'm just in a wondering mood today. And I'm writing a REXX application "in my off time" (and I can be quite "off" at times). But I wondering if REXX on z/OS is really used much beyond ISPF macros and the occasional TSO command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write UNIX scripts in REXX?

I'm writing a "trimodal" REXX program. I am designing it to run as a normal ISPF application; as a UNIX application under TSO OMVS (using the pt3270 interface so that it is really the aforementioned ISPF application); and as a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have any kind of "windowing" package for REXX, like "curses" for C.

--
"Irrigation of the land with seawater desalinated by fusion power is ancient. It's called 'rain'." -- Michael McClary, in alt.fusion

Maranatha! <><
John McKown

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions, send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Farley, Peter x23353
2017-04-12 16:06:17 UTC
Permalink
Raw Message
John,

I use a fair number of Rexx scripts under both IRXJCL (when no TSO commands are needed) and IKJEFT01 (for TSO commands) for lots of "side work" we programmers have to do that is administrative in nature (i.e., paperwork nonsense).

So far no Unix Rexx though. I do use an SDSF Rexx script that I wrote for extracting DSID's from SDSF by DD name. Works a treat.

And no, your questions are not offensive here at all.

Peter

-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of John McKown
Sent: Wednesday, April 12, 2017 9:50 AM
To: TSO-***@VM.MARIST.EDU
Subject: curious: Uses of REXX.

Hope this isn't so off-topic as to be offensive.

I'm just in a wondering mood today. And I'm writing a REXX application "in
my off time" (and I can be quite "off" at times). But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write
UNIX scripts in REXX?

I'm writing a "trimodal" REXX program. I am designing it to run as a normal
ISPF application; as a UNIX application under TSO OMVS (using the pt3270
interface so that it is really the aforementioned ISPF application); and as
a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to
via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have
any kind of "windowing" package for REXX, like "curses" for C.

--


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.
Pfister, Nathan
2017-04-12 16:20:44 UTC
Permalink
Raw Message
John;

As a younger systems programmer who is not as good at assembler as my more seasoned counterparts, I am a heavy user of REXX (meaning what a lot of the more seasoned sysprogs are writing in Assembler, I am writing in REXX, since in my opinion it is quicker and easier to modify REXX even though it may not run as fast). Outside of the ISPF macros, I use many IIKJEFT01 batch REXX scripts for everything from reporting to small automation bits and pieces. I also have written quite a few TSO commands in REXX to save myself on every day administrative things. I had, at a past job, done some things on the UNIX shell side with an intermixing of REXX and shell scripting, but alas outside the standard pieces of USS here we are not heavy users.

Thanks;
Nathan Pfister
-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of John McKown
Sent: Wednesday, April 12, 2017 9:50 AM
To: TSO-***@VM.MARIST.EDU
Subject: [TSO-REXX] curious: Uses of REXX.

Hope this isn't so off-topic as to be offensive.

I'm just in a wondering mood today. And I'm writing a REXX application "in my off time" (and I can be quite "off" at times). But I wondering if REXX on z/OS is really used much beyond ISPF macros and the occasional TSO command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write UNIX scripts in REXX?

I'm writing a "trimodal" REXX program. I am designing it to run as a normal ISPF application; as a UNIX application under TSO OMVS (using the pt3270 interface so that it is really the aforementioned ISPF application); and as a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have any kind of "windowing" package for REXX, like "curses" for C.

--
"Irrigation of the land with seawater desalinated by fusion power is ancient. It's called 'rain'." -- Michael McClary, in alt.fusion

Maranatha! <><
John McKown

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions, send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
E-MAIL CONFIDENTIALITY NOTICE: This e-mail from Donegal Insurance Group may contain CONFIDENTIAL and legally protected information. If you are not an intended recipient, please do not copy, use or disclose this email or its contents to others; and please notify us by calling toll free (800) 877-0600 x7880 or by replying to this message, and then delete it from your system. Delivery of this email to an unintended recipient is not a waiver of any attorney-client or other applicable privilege.
Jesse 1 Robinson
2017-04-12 16:50:34 UTC
Permalink
Raw Message
I'm an older sysprog who can write assembler but prefers REXX whenever feasible. When TSO/E introduced REXX back in 19??, I resolved never to write another CLIST. (Of course I tweak an existing CLIST as necessary, but any new app is written in REXX.) TSO/E REXX was pretty primitive in the early days. I had to code with an open manual and run frequently for help to VM colleagues, who were sometimes befuddled by the language differences.

I've tried non-TSO (IXRJCL) a few times, but I seldom get very far without needing a TSO function as simple as allocation. So I almost always run with IKJEFT1x. I'm a big fan of batch ISPF apps using REXX. ISPF tables rule.

Never tried a REXX for UNIX.

.
.
J.O.Skip Robinson
Southern California Edison Company
Electric Dragon Team Paddler
SHARE MVS Program Co-Manager
323-715-0595 Mobile
626-543-6132 Office ⇐=== NEW
***@sce.com


-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of Pfister, Nathan
Sent: Wednesday, April 12, 2017 9:20 AM
To: TSO-***@VM.MARIST.EDU
Subject: (External):Re: [TSO-REXX] curious: Uses of REXX.

John;

As a younger systems programmer who is not as good at assembler as my more seasoned counterparts, I am a heavy user of REXX (meaning what a lot of the more seasoned sysprogs are writing in Assembler, I am writing in REXX, since in my opinion it is quicker and easier to modify REXX even though it may not run as fast). Outside of the ISPF macros, I use many IIKJEFT01 batch REXX scripts for everything from reporting to small automation bits and pieces. I also have written quite a few TSO commands in REXX to save myself on every day administrative things. I had, at a past job, done some things on the UNIX shell side with an intermixing of REXX and shell scripting, but alas outside the standard pieces of USS here we are not heavy users.

Thanks;
Nathan Pfister
-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of John McKown
Sent: Wednesday, April 12, 2017 9:50 AM
To: TSO-***@VM.MARIST.EDU
Subject: [TSO-REXX] curious: Uses of REXX.

Hope this isn't so off-topic as to be offensive.

I'm just in a wondering mood today. And I'm writing a REXX application "in my off time" (and I can be quite "off" at times). But I wondering if REXX on z/OS is really used much beyond ISPF macros and the occasional TSO command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write UNIX scripts in REXX?

I'm writing a "trimodal" REXX program. I am designing it to run as a normal ISPF application; as a UNIX application under TSO OMVS (using the pt3270 interface so that it is really the aforementioned ISPF application); and as a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have any kind of "windowing" package for REXX, like "curses" for C.

--
"Irrigation of the land with seawater desalinated by fusion power is ancient. It's called 'rain'." -- Michael McClary, in alt.fusion

Maranatha! <><
John McKown
Paul Gilmartin
2017-04-12 17:08:30 UTC
Permalink
Raw Message
Post by Jesse 1 Robinson
I've tried non-TSO (IXRJCL) a few times, but I seldom get very far without needing a TSO function as simple as allocation.
For allocation, there's BPXWDYN with extras such as RTDDN, INFO,
and CONCAT. But for many other things such as ISPF and LISTDSI
you need the TMP.
Post by Jesse 1 Robinson
So I almost always run with IKJEFT1x. I'm a big fan of batch ISPF apps using REXX. ISPF tables rule.
Never tried a REXX for UNIX.
It has the same constraints as IRXJCL but the addition of ADDRESS SH.
BPXWUNIX gives you shell facilities from TSO, IRXJCL, or UNIX plus
allowing capture of UNIX output (and input) in stems, OUTTRAP-like.

-- gil

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Anania, Philip D
2017-04-12 17:05:05 UTC
Permalink
Raw Message
I use IRXJC and IKJEFT* all the time. Our shop and the stuff our team
supports is very customized with lots O' batch REXX. We interface with
UNIX as well via SYSCALL, BXPBATCH and BPXUNIX. I guess we are the
opposite of your experience as while we do have some EDIT Macros most of
our stuff is for batch processing.
Post by John McKown
Hope this isn't so off-topic as to be offensive.
I'm just in a wondering mood today. And I'm writing a REXX application "in
my off time" (and I can be quite "off" at times). But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write
UNIX scripts in REXX?
I'm writing a "trimodal" REXX program. I am designing it to run as a normal
ISPF application; as a UNIX application under TSO OMVS (using the pt3270
interface so that it is really the aforementioned ISPF application); and as
a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to
via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have
any kind of "windowing" package for REXX, like "curses" for C.
--
"Irrigation of the land with seawater desalinated by fusion power is
ancient. It's called 'rain'." -- Michael McClary, in alt.fusion
Maranatha! <><
John McKown
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--

"Go about your Music citizen"

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Dyck, Lionel B. , TRA
2017-04-12 17:11:58 UTC
Permalink
Raw Message
I use REXX for ISPF dialogs as well as ISPF Edit macros. I have also used it for OMVS scripting and have 1/2 dozen scripts running out of cron on a regular schedule.

Not used IRXJCL.

--------------------------------------------------------------------------
Lionel B. Dyck
Mainframe Systems Programmer - TRA
Enterprise Operations (Station 200) (005OP6.3.10)
Information and Technology, IT Operations and Services
Paul Gilmartin
2017-04-12 17:13:23 UTC
Permalink
Raw Message
Post by Anania, Philip D
I use IRXJC and IKJEFT* all the time. Our shop and the stuff our team
supports is very customized with lots O' batch REXX. We interface with
UNIX as well via SYSCALL, BXPBATCH and BPXUNIX. I guess we are the
opposite of your experience as while we do have some EDIT Macros most of
our stuff is for batch processing.
Of course you can use EDIT macros in batch. However the setup is tedious.

-- gil

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Mickey Bee
2017-04-13 23:48:57 UTC
Permalink
Raw Message
In the early 90s, I wrote a 3200 line edit macro in Rexx that would convert
a Honeywell Cobol program using TP4 or TP8 as a transaction handler, and
IDS2 as a database into COBOL2, DB2, CICS.

Mickey

-----Original Message-----
From: Anania, Philip D
Sent: Wednesday, April 12, 2017 1:05 PM
To: TSO-***@VM.MARIST.EDU
Subject: Re: [TSO-REXX] curious: Uses of REXX.

I use IRXJC and IKJEFT* all the time. Our shop and the stuff our team
supports is very customized with lots O' batch REXX. We interface with
UNIX as well via SYSCALL, BXPBATCH and BPXUNIX. I guess we are the
opposite of your experience as while we do have some EDIT Macros most of
our stuff is for batch processing.
Post by John McKown
Hope this isn't so off-topic as to be offensive.
I'm just in a wondering mood today. And I'm writing a REXX application "in
my off time" (and I can be quite "off" at times). But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write
UNIX scripts in REXX?
I'm writing a "trimodal" REXX program. I am designing it to run as a normal
ISPF application; as a UNIX application under TSO OMVS (using the pt3270
interface so that it is really the aforementioned ISPF application); and as
a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to
via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have
any kind of "windowing" package for REXX, like "curses" for C.
--
"Irrigation of the land with seawater desalinated by fusion power is
ancient. It's called 'rain'." -- Michael McClary, in alt.fusion
Maranatha! <><
John McKown
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--

"Go about your Music citizen"

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Anania, Philip D
2017-04-12 17:06:42 UTC
Permalink
Raw Message
Forgot to mention we use SDSF REXX as well...
Post by John McKown
Hope this isn't so off-topic as to be offensive.
I'm just in a wondering mood today. And I'm writing a REXX application "in
my off time" (and I can be quite "off" at times). But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command. In particular, does anyone (else) use REXX with IRXJCL in batch?
What about TSO REXX in batch via IKJEFT01? And, biggie for me, to write
UNIX scripts in REXX?
I'm writing a "trimodal" REXX program. I am designing it to run as a normal
ISPF application; as a UNIX application under TSO OMVS (using the pt3270
interface so that it is really the aforementioned ISPF application); and as
a UNIX shell script not under TSO OMVS (i.e. from a UNIX shell gotten to
via "telnet" or "ssh"). The latter is a pain since z/OS UNIX doesn't have
any kind of "windowing" package for REXX, like "curses" for C.
--
"Irrigation of the land with seawater desalinated by fusion power is
ancient. It's called 'rain'." -- Michael McClary, in alt.fusion
Maranatha! <><
John McKown
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--

"Go about your Music citizen"

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Bill Schoen
2017-04-12 23:41:43 UTC
Permalink
Raw Message
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create for
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.

Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Paul Gilmartin
2017-04-13 00:05:42 UTC
Permalink
Raw Message
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create for
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
If it takes WJS an hour, it might take a mortal a month.
Post by Bill Schoen
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
Are these samples downloadable?
Post by Bill Schoen
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
I think I understand the Bad History and reusability behind this. But
it shouldn't be necessary. SAY should just build a string, add one
<newline>, and SYSCALL write. In contrast, Regina Rexx:

556 $ uname -a
Darwin PaulGilm.local 10.8.0 Darwin Kernel Version 10.8.0: Tue Jun 7 16:33:36 PDT 2011; root:xnu-1504.15.3~1/RELEASE_I386 i386
557 $
557 $ rxx "trace R; parse version .; trace N; say left('',99999,x)" | wc
2 *-* interpret arg( 1 )
Post by Bill Schoen
.> "REXX-Regina_3.6B1 5.00 14 Jun 2010"
*-* interpret arg( 1 )
1 1 100000
558 $

(I notice Regina sends TRACE output to stderr, something that's
been discussed and wished for here.)

-- gil

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Bill Lee
2017-04-13 01:04:56 UTC
Permalink
Raw Message
Bill,

I have done a lot of REXX CGI and I am intrigued by your comment about
a REXX API to a web enablement toolkit. First I have heard of it. Can
you please point me in the right direction where I can learn more and
possibly some examples?

Thx,
Bill Lee
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create for
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--
--------------------------------------------------
This e-mail transmission contains information intended only for the use of
the recipient(s) named above. Further, it contains information that may be
privileged and confidential. If you are not the intended recipient, you
are hereby notified that any dissemination, distribution, or copying of
this message (including any attachments) is strictly prohibited. If you
have received this e-mail in error, please notify the sender by reply
e-mail and then delete this message from your mail system. Thank you for
your compliance.

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Bill Schoen
2017-04-13 01:15:10 UTC
Permalink
Raw Message
https://www.ibm.com/support/knowledgecenter/en/SSLTBW_2.2.0/com.ibm.zos.v2r2.ieac100/ieac1-client-web-enablement.htm
Post by Bill Lee
Bill,
I have done a lot of REXX CGI and I am intrigued by your comment about
a REXX API to a web enablement toolkit. First I have heard of it. Can
you please point me in the right direction where I can learn more and
possibly some examples?
Thx,
Bill Lee
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create for
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--
--------------------------------------------------
This e-mail transmission contains information intended only for the use of
the recipient(s) named above. Further, it contains information that may be
privileged and confidential. If you are not the intended recipient, you
are hereby notified that any dissemination, distribution, or copying of
this message (including any attachments) is strictly prohibited. If you
have received this e-mail in error, please notify the sender by reply
e-mail and then delete this message from your mail system. Thank you for
your compliance.
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Bill Turner, WB4ALM
2017-04-13 01:11:08 UTC
Permalink
Raw Message
1. I create html pages with a series of rexx scripts. SAY has not been
a problem with the inserted CR/LKF at the end of each SAY.


2. I use ooRexx external to MVS/ZOS, and most of my applications can run
under MVS/ZOS/VM and WINDOWS/LINUX/OSX with the appropiate use of SELECT
and the PARSE SOURCE statements.
I do a PARSE SOURCE at the beginning of the module, and use SELECT
statements later on to do the appropiate file allocation and file
read/writes.


3. Because IO is the major difference from system to system, I read
input files into arrays, and then place the output into other arrays.
File reading and final output can then be done via subroutine and all at
once - minimizing the amount of time that a file is physically open.


4. I also used a naming convention for my files.
FILE1 is generally an input file.
FILE2is generally THE output file.
File3 thru FINEn can be input or output files as needed.
FILE1DSN is the file name
FILE1PTR is a record pointer
FILE1. is the array name
FILE1.0 is used to hold the size of the array
(and generally is updated just after reading the
entire file; or just before writing the entire file.)
Since a lot of what I used to do on the Mainframe was "quick and
dirties" my output routine normally deletes the (or any) existing file,
and then recreates it.

On a large mainframe, this also had the advantage to minimizing the
amount of time I was enqueued on the output file.

FILE1DSN=''; FILE1.=''; FILE1.0=0; FILE1PTR=0 was my normal
preallocation of the main variables.

On TSO/MVS/ZOS I generally had additional variables such as
FILE1LRECL FILE1BLKSIZE etc.
My ALLOC statement generally allocated the file to an appropriate
ddname such as FILE1DD

This entire process allowed me to reuse code without having to think
about it too much as well...

Obviously you change the "1" in each of these variables to an
appropriate file number.


5. In the case of an APACHE server, there is a "rexxmod" which can be
used to allow full support of web pages WRITTEN in Rexx. Check
Sourceforge.net for details.


6. While I have never done so, I suspect that rexx can be used as a CGI
language - and this might be where the CR/LF of SAY might be a small
problem.


/s/ Bill Turner, wb4alm
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create for
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the
time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Bill Schoen
2017-04-13 01:21:17 UTC
Permalink
Raw Message
nl at the end of a SAY isn't an issue.
It's the lrecl of TSO REXX that causes long SAY output to be broken into
multiple lines with nl inserted at line breaks within the long string.

Bill Schoen
1. I create html pages with a series of rexx scripts. SAY has not been
a problem with the inserted CR/LKF at the end of each SAY.
2. I use ooRexx external to MVS/ZOS, and most of my applications can run
under MVS/ZOS/VM and WINDOWS/LINUX/OSX with the appropiate use of SELECT
and the PARSE SOURCE statements.
I do a PARSE SOURCE at the beginning of the module, and use SELECT
statements later on to do the appropiate file allocation and file
read/writes.
3. Because IO is the major difference from system to system, I read
input files into arrays, and then place the output into other arrays.
File reading and final output can then be done via subroutine and all at
once - minimizing the amount of time that a file is physically open.
4. I also used a naming convention for my files.
FILE1 is generally an input file.
FILE2is generally THE output file.
File3 thru FINEn can be input or output files as needed.
FILE1DSN is the file name
FILE1PTR is a record pointer
FILE1. is the array name
FILE1.0 is used to hold the size of the array
(and generally is updated just after reading the
entire file; or just before writing the entire file.)
Since a lot of what I used to do on the Mainframe was "quick and
dirties" my output routine normally deletes the (or any) existing file,
and then recreates it.
On a large mainframe, this also had the advantage to minimizing the
amount of time I was enqueued on the output file.
FILE1DSN=''; FILE1.=''; FILE1.0=0; FILE1PTR=0 was my normal
preallocation of the main variables.
On TSO/MVS/ZOS I generally had additional variables such as
FILE1LRECL FILE1BLKSIZE etc.
My ALLOC statement generally allocated the file to an appropriate
ddname such as FILE1DD
This entire process allowed me to reuse code without having to think
about it too much as well...
Obviously you change the "1" in each of these variables to an
appropriate file number.
5. In the case of an APACHE server, there is a "rexxmod" which can be
used to allow full support of web pages WRITTEN in Rexx. Check
Sourceforge.net for details.
6. While I have never done so, I suspect that rexx can be used as a CGI
language - and this might be where the CR/LF of SAY might be a small
problem.
/s/ Bill Turner, wb4alm
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create for
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Paul Gilmartin
2017-04-13 02:29:55 UTC
Permalink
Raw Message
Post by Bill Schoen
nl at the end of a SAY isn't an issue.
It's the lrecl of TSO REXX that causes long SAY output to be broken into
multiple lines with nl inserted at line breaks within the long string.
Understood. What I don't understand is why Rexx for UNIX System Services
should be bound by the constraints of TSO REXX.

In fact, I believe LINE_MAX is 2048, but UNIX Rexx wraps at about half that.
Post by Bill Schoen
1. I create html pages with a series of rexx scripts. SAY has not been
a problem with the inserted CR/LKF at the end of each SAY.
If your lines are short or you're using a Rexx other than TSO's,
you'll have no problem.

-- gil

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Hobart Spitz
2017-04-13 13:51:18 UTC
Permalink
Raw Message
I have a huge amount to say, but I'll make this somewhat brief.

In the early 90s, I worked on system with a multiple phase batch process
that had multiple clients each of which had multiple billing cycles. There
were hundreds of JCL streams, one for each possible phase, client and
billing cycle combination. We converted the JCL to REXX and were able to
reduce the JCL streams to one per phase, about a dozen. The key was that
we were able to interrogate a DB2 table from REXX, make decisions about
what work was ready, allocate the needed client and billing cycle DDs, and
to update billing cycle status on phase completion, also from REXX.

Based on this experience, I wrote a talk entitled "Converting JCL to REXX",
which I gave at SHARE a number of times. You can probably still find it on
the web. I fully expected everyone to rush home from the conference and
throw out most of their JCL. Instead, more than 20 years later, people are
still asking basic questions about using REXX in batch. (I see no good
reason to use IRXJCL, for example; maybe someone else does. Start with
IKJEFT01 called from a single generic PROC. Why have one arm tied behind
your back?)

I don't know if I hit a nerve, but a few years after the talk, IBM added
IF, INCLUDE, SET, nested PROC invocations, etc. to JCL.

Replacing your JCL with REXX may sound hard, but keep in mind that z/OS is
one of the few major operating systems that has different scripting
languages for batch and foreground. Think UNIX/LINUX, and z/VM; they don't
have JCL, and the batch capabilities are much broader than in z/OS.

The bottom line:

- If you look at TSO commands such as ALLOC, etc., you'll see that their
are direct TSO equivalents for almost all JCL constructs. JOB and JES
commands are the main exceptions; you will be keeping them.
- 99% of all JCL can be replaced with REXX running in batch under
IKJEFT01, with significant advantages.
- Write a generic TSO PROC once, with all the logon proc DDs, and it's
easy from there.
- There is inertia to converting JCL to REXX, so anytime you write a new
JCL step (or make major revisions), think REXX instead.
- Consecutive steps of IKJEFT01, IDCAMS, SORT, and other utilities are
opportunities to gradually phase in batch REXX. Combine those consecutive
steps into one.
- Batch ISPF is just slightly harder, but you only have to solve the
problem once. Look up ZISPFRC, allocate ISPLOG to SYSOUT=* and have your
ISPF PROC call your TSO PROC.
- If you really want your batch system to perform, get the TSO PIPE
command.

I've been thinking of updating my talk with a different approach, possibly
oriented towards writing batch REXX. I've been working under z/VM for much
of the last 15 years (where there is no JCL and you always have PIPEs...
yay!), so I'd be happy to hear what others have to say that would fill in
any gaps in my knowledge.

Thanks in advance.
Post by Bill Schoen
nl at the end of a SAY isn't an issue.
It's the lrecl of TSO REXX that causes long SAY output to be broken into
multiple lines with nl inserted at line breaks within the long string.
Bill Schoen
1. I create html pages with a series of rexx scripts. SAY has not been
a problem with the inserted CR/LKF at the end of each SAY.
2. I use ooRexx external to MVS/ZOS, and most of my applications can run
under MVS/ZOS/VM and WINDOWS/LINUX/OSX with the appropiate use of SELECT
and the PARSE SOURCE statements.
I do a PARSE SOURCE at the beginning of the module, and use SELECT
statements later on to do the appropiate file allocation and file
read/writes.
3. Because IO is the major difference from system to system, I read
input files into arrays, and then place the output into other arrays.
File reading and final output can then be done via subroutine and all at
once - minimizing the amount of time that a file is physically open.
4. I also used a naming convention for my files.
FILE1 is generally an input file.
FILE2is generally THE output file.
File3 thru FINEn can be input or output files as needed.
FILE1DSN is the file name
FILE1PTR is a record pointer
FILE1. is the array name
FILE1.0 is used to hold the size of the array
(and generally is updated just after reading the
entire file; or just before writing the entire file.)
Since a lot of what I used to do on the Mainframe was "quick and
dirties" my output routine normally deletes the (or any) existing file,
and then recreates it.
On a large mainframe, this also had the advantage to minimizing the
amount of time I was enqueued on the output file.
FILE1DSN=''; FILE1.=''; FILE1.0=0; FILE1PTR=0 was my normal
preallocation of the main variables.
On TSO/MVS/ZOS I generally had additional variables such as
FILE1LRECL FILE1BLKSIZE etc.
My ALLOC statement generally allocated the file to an appropriate
ddname such as FILE1DD
This entire process allowed me to reuse code without having to think
about it too much as well...
Obviously you change the "1" in each of these variables to an
appropriate file number.
5. In the case of an APACHE server, there is a "rexxmod" which can be
used to allow full support of web pages WRITTEN in Rexx. Check
Sourceforge.net for details.
6. While I have never done so, I suspect that rexx can be used as a CGI
language - and this might be where the CR/LF of SAY might be a small
problem.
/s/ Bill Turner, wb4alm
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create for
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--
OREXXMan

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
John McKown
2017-04-13 18:45:58 UTC
Permalink
Raw Message
Post by Hobart Spitz
I have a huge amount to say, but I'll make this somewhat brief.
In the early 90s, I worked on system with a multiple phase batch process
that had multiple clients each of which had multiple billing cycles. There
were hundreds of JCL streams, one for each possible phase, client and
billing cycle combination. We converted the JCL to REXX and were able to
reduce the JCL streams to one per phase, about a dozen. The key was that
we were able to interrogate a DB2 table from REXX, make decisions about
what work was ready, allocate the needed client and billing cycle DDs, and
to update billing cycle status on phase completion, also from REXX.
Based on this experience, I wrote a talk entitled "Converting JCL to REXX",
which I gave at SHARE a number of times. You can probably still find it on
the web. I fully expected everyone to rush home from the conference and
throw out most of their JCL. Instead, more than 20 years later, people are
still asking basic questions about using REXX in batch. (I see no good
reason to use IRXJCL, for example; maybe someone else does. Start with
IKJEFT01 called from a single generic PROC. Why have one arm tied behind
your back?)
I don't know if I hit a nerve, but a few years after the talk, IBM added
IF, INCLUDE, SET, nested PROC invocations, etc. to JCL.
Replacing your JCL with REXX may sound hard, but keep in mind that z/OS is
one of the few major operating systems that has different scripting
languages for batch and foreground. Think UNIX/LINUX, and z/VM; they don't
have JCL, and the batch capabilities are much broader than in z/OS.
- If you look at TSO commands such as ALLOC, etc., you'll see that their
are direct TSO equivalents for almost all JCL constructs. JOB and JES
commands are the main exceptions; you will be keeping them.
- 99% of all JCL can be replaced with REXX running in batch under
IKJEFT01, with significant advantages.
- Write a generic TSO PROC once, with all the logon proc DDs, and it's
easy from there.
- There is inertia to converting JCL to REXX, so anytime you write a new
JCL step (or make major revisions), think REXX instead.
​ - Consecutive steps of IKJEFT01, IDCAMS, SORT, and other utilities are
Post by Hobart Spitz
opportunities to gradually phase in batch REXX. Combine those consecutive
steps into one.
​​

​I only have one question about this: "What do you use to restart instead
of CA-11?". The major problem that I have with using REXX instead of JCL is
exactly this one. I'm not meaning writing a REXX program to do what would,
historically, be done in a COBOL program, but a REXX program which
basically just duplicates what has historically been done by running
multiple steps in JCL. To my knowledge, there is just not a generic package
to do this sort of thing. And asking a production control person at 02:30
to do some sort of modification, even just changing the JCL from
//STEP EXEC PGM=IKJEFT1A,PARM='%REXXPGM RUN'
to
//STEP EXEC PGM=IKJEFT1A,PARM='REXXPGM RESTART STEP2"

is really pushing things. IMO. But perhaps I'm being too disparaging of
your off hours production people.​ Also the REXX program needs to be smart
enough to detect an "abend" or "bad return code" condition and stop with an
_UNDERSTANDABLE_ error message so that the production person can have some
idea what to say to an on-call person. And that's not getting into
"conditional disposition" on a DD, which now needs to be handled by the
REXX code as well.
Post by Hobart Spitz
- Batch ISPF is just slightly harder, but you only have to solve the
problem once. Look up ZISPFRC, allocate ISPLOG to SYSOUT=* and have your
ISPF PROC call your TSO PROC.
- If you really want your batch system to perform, get the TSO PIPE
command.
​I've never seen TSO PIPE, but I've heard & seen a bit about CMS PIPE on
the z/VM forum. I've always wondered if a UNIX pipe could be used instead.​
Post by Hobart Spitz
I've been thinking of updating my talk with a different approach, possibly
oriented towards writing batch REXX. I've been working under z/VM for much
of the last 15 years (where there is no JCL and you always have PIPEs...
yay!), so I'd be happy to hear what others have to say that would fill in
any gaps in my knowledge.
Thanks in advance.
--
"Irrigation of the land with seawater desalinated by fusion power is
ancient. It's called 'rain'." -- Michael McClary, in alt.fusion

Maranatha! <><
John McKown

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Anania, Philip D
2017-04-13 19:09:44 UTC
Permalink
Raw Message
IRXJCL...

I work with Endevor and we recently went through the process of building
processors to allow our developers to deal with JAR and WebSphere files so
we had to interface with UNIX. Originally we used BPXBATCH and we got it
to work but CA claims that running BPXBATCH within a REXX under IKJEFT* is
a bad idea because the UNIX steps become spawned jobs and therefore the
handoff between the Endevor Security and the UNIX permissions is not
guaranteed, We got it to work and never experienced any issues once we
figured things out (none of us were UNIX folks) but because CA recommends
not using BPXBATCH we looked at alternatives. We then went to SYSCALL and
eventually to BPXWUNIX. We found that BPXWUNIX needs IRXJCL at least to
work from within Endevor processors. For those unaware with Endevor, it is
actually all assembler stuff under the covers even if it looks like JCL. I
cannot speak about why IRXJCL ended up being the method but we got it to
work and CA was happy. We banged out heads against the wall a lot but
finally got things humming. Obviously we had to find equivalent commands
for any TSO commands but we found what we needed.

This may be the only place where IRXJCL trumps IKJEFT*.

P
Post by Hobart Spitz
I have a huge amount to say, but I'll make this somewhat brief.
In the early 90s, I worked on system with a multiple phase batch process
that had multiple clients each of which had multiple billing cycles. There
were hundreds of JCL streams, one for each possible phase, client and
billing cycle combination. We converted the JCL to REXX and were able to
reduce the JCL streams to one per phase, about a dozen. The key was that
we were able to interrogate a DB2 table from REXX, make decisions about
what work was ready, allocate the needed client and billing cycle DDs, and
to update billing cycle status on phase completion, also from REXX.
Based on this experience, I wrote a talk entitled "Converting JCL to REXX",
which I gave at SHARE a number of times. You can probably still find it on
the web. I fully expected everyone to rush home from the conference and
throw out most of their JCL. Instead, more than 20 years later, people are
still asking basic questions about using REXX in batch. (I see no good
reason to use IRXJCL, for example; maybe someone else does. Start with
IKJEFT01 called from a single generic PROC. Why have one arm tied behind
your back?)
I don't know if I hit a nerve, but a few years after the talk, IBM added
IF, INCLUDE, SET, nested PROC invocations, etc. to JCL.
Replacing your JCL with REXX may sound hard, but keep in mind that z/OS is
one of the few major operating systems that has different scripting
languages for batch and foreground. Think UNIX/LINUX, and z/VM; they don't
have JCL, and the batch capabilities are much broader than in z/OS.
- If you look at TSO commands such as ALLOC, etc., you'll see that their
are direct TSO equivalents for almost all JCL constructs. JOB and JES
commands are the main exceptions; you will be keeping them.
- 99% of all JCL can be replaced with REXX running in batch under
IKJEFT01, with significant advantages.
- Write a generic TSO PROC once, with all the logon proc DDs, and it's
easy from there.
- There is inertia to converting JCL to REXX, so anytime you write a new
JCL step (or make major revisions), think REXX instead.
- Consecutive steps of IKJEFT01, IDCAMS, SORT, and other utilities are
opportunities to gradually phase in batch REXX. Combine those consecutive
steps into one.
- Batch ISPF is just slightly harder, but you only have to solve the
problem once. Look up ZISPFRC, allocate ISPLOG to SYSOUT=* and have your
ISPF PROC call your TSO PROC.
- If you really want your batch system to perform, get the TSO PIPE
command.
I've been thinking of updating my talk with a different approach, possibly
oriented towards writing batch REXX. I've been working under z/VM for much
of the last 15 years (where there is no JCL and you always have PIPEs...
yay!), so I'd be happy to hear what others have to say that would fill in
any gaps in my knowledge.
Thanks in advance.
Post by Bill Schoen
nl at the end of a SAY isn't an issue.
It's the lrecl of TSO REXX that causes long SAY output to be broken into
multiple lines with nl inserted at line breaks within the long string.
Bill Schoen
1. I create html pages with a series of rexx scripts. SAY has not been
a problem with the inserted CR/LKF at the end of each SAY.
2. I use ooRexx external to MVS/ZOS, and most of my applications can run
under MVS/ZOS/VM and WINDOWS/LINUX/OSX with the appropiate use of SELECT
and the PARSE SOURCE statements.
I do a PARSE SOURCE at the beginning of the module, and use SELECT
statements later on to do the appropiate file allocation and file
read/writes.
3. Because IO is the major difference from system to system, I read
input files into arrays, and then place the output into other arrays.
File reading and final output can then be done via subroutine and all at
once - minimizing the amount of time that a file is physically open.
4. I also used a naming convention for my files.
FILE1 is generally an input file.
FILE2is generally THE output file.
File3 thru FINEn can be input or output files as needed.
FILE1DSN is the file name
FILE1PTR is a record pointer
FILE1. is the array name
FILE1.0 is used to hold the size of the array
(and generally is updated just after reading the
entire file; or just before writing the entire file.)
Since a lot of what I used to do on the Mainframe was "quick and
dirties" my output routine normally deletes the (or any) existing file,
and then recreates it.
On a large mainframe, this also had the advantage to minimizing the
amount of time I was enqueued on the output file.
FILE1DSN=''; FILE1.=''; FILE1.0=0; FILE1PTR=0 was my normal
preallocation of the main variables.
On TSO/MVS/ZOS I generally had additional variables such as
FILE1LRECL FILE1BLKSIZE etc.
My ALLOC statement generally allocated the file to an appropriate
ddname such as FILE1DD
This entire process allowed me to reuse code without having to think
about it too much as well...
Obviously you change the "1" in each of these variables to an
appropriate file number.
5. In the case of an APACHE server, there is a "rexxmod" which can be
used to allow full support of web pages WRITTEN in Rexx. Check
Sourceforge.net for details.
6. While I have never done so, I suspect that rexx can be used as a CGI
language - and this might be where the CR/LF of SAY might be a small
problem.
/s/ Bill Turner, wb4alm
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create
for
Post by Bill Schoen
Post by Bill Schoen
github issues.
Scripting CGIs along with the REXX API to the web enablement toolkit,
especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout() if
you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--
OREXXMan
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
--

"Go about your Music citizen"

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Paul Gillis
2017-04-13 22:25:46 UTC
Permalink
Raw Message
There was discussion loosely related to this topic on IBM-Main a few years ago. I worked with a product called JOL that replaced JCL and was used by Shell Australia amongst others to replace all their batch production JCL.
https://listserv.ua.edu/cgi-bin/wa?A2=ind1001&L=IBM-MAIN&D=0&I=-3&X=20C0348465BD743C0D&d=No+Match%3BMatch%3BMatches&P=123119

Paul Gillis

-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of Hobart Spitz
Sent: Thursday, 13 April 2017 11:52 PM
To: TSO-***@VM.MARIST.EDU
Subject: Re: [TSO-REXX] curious: Uses of REXX.

I have a huge amount to say, but I'll make this somewhat brief.

In the early 90s, I worked on system with a multiple phase batch process that had multiple clients each of which had multiple billing cycles. There were hundreds of JCL streams, one for each possible phase, client and billing cycle combination. We converted the JCL to REXX and were able to reduce the JCL streams to one per phase, about a dozen. The key was that we were able to interrogate a DB2 table from REXX, make decisions about what work was ready, allocate the needed client and billing cycle DDs, and to update billing cycle status on phase completion, also from REXX.

Based on this experience, I wrote a talk entitled "Converting JCL to REXX", which I gave at SHARE a number of times. You can probably still find it on the web. I fully expected everyone to rush home from the conference and throw out most of their JCL. Instead, more than 20 years later, people are still asking basic questions about using REXX in batch. (I see no good reason to use IRXJCL, for example; maybe someone else does. Start with
IKJEFT01 called from a single generic PROC. Why have one arm tied behind your back?)

I don't know if I hit a nerve, but a few years after the talk, IBM added IF, INCLUDE, SET, nested PROC invocations, etc. to JCL.

Replacing your JCL with REXX may sound hard, but keep in mind that z/OS is one of the few major operating systems that has different scripting languages for batch and foreground. Think UNIX/LINUX, and z/VM; they don't have JCL, and the batch capabilities are much broader than in z/OS.

The bottom line:

- If you look at TSO commands such as ALLOC, etc., you'll see that their
are direct TSO equivalents for almost all JCL constructs. JOB and JES
commands are the main exceptions; you will be keeping them.
- 99% of all JCL can be replaced with REXX running in batch under
IKJEFT01, with significant advantages.
- Write a generic TSO PROC once, with all the logon proc DDs, and it's
easy from there.
- There is inertia to converting JCL to REXX, so anytime you write a new
JCL step (or make major revisions), think REXX instead.
- Consecutive steps of IKJEFT01, IDCAMS, SORT, and other utilities are
opportunities to gradually phase in batch REXX. Combine those consecutive
steps into one.
- Batch ISPF is just slightly harder, but you only have to solve the
problem once. Look up ZISPFRC, allocate ISPLOG to SYSOUT=* and have your
ISPF PROC call your TSO PROC.
- If you really want your batch system to perform, get the TSO PIPE
command.

I've been thinking of updating my talk with a different approach, possibly oriented towards writing batch REXX. I've been working under z/VM for much of the last 15 years (where there is no JCL and you always have PIPEs...
yay!), so I'd be happy to hear what others have to say that would fill in any gaps in my knowledge.

Thanks in advance.
Post by Bill Schoen
nl at the end of a SAY isn't an issue.
It's the lrecl of TSO REXX that causes long SAY output to be broken
into multiple lines with nl inserted at line breaks within the long string.
Bill Schoen
1. I create html pages with a series of rexx scripts. SAY has not
been a problem with the inserted CR/LKF at the end of each SAY.
2. I use ooRexx external to MVS/ZOS, and most of my applications can
run under MVS/ZOS/VM and WINDOWS/LINUX/OSX with the appropiate use of
SELECT and the PARSE SOURCE statements.
I do a PARSE SOURCE at the beginning of the module, and use SELECT
statements later on to do the appropiate file allocation and file
read/writes.
3. Because IO is the major difference from system to system, I read
input files into arrays, and then place the output into other arrays.
File reading and final output can then be done via subroutine and all
at once - minimizing the amount of time that a file is physically open.
4. I also used a naming convention for my files.
FILE1 is generally an input file.
FILE2is generally THE output file.
File3 thru FINEn can be input or output files as needed.
FILE1DSN is the file name
FILE1PTR is a record pointer
FILE1. is the array name
FILE1.0 is used to hold the size of the array
(and generally is updated just after reading the
entire file; or just before writing the entire file.)
Since a lot of what I used to do on the Mainframe was "quick and
dirties" my output routine normally deletes the (or any) existing
file, and then recreates it.
On a large mainframe, this also had the advantage to minimizing
the amount of time I was enqueued on the output file.
FILE1DSN=''; FILE1.=''; FILE1.0=0; FILE1PTR=0 was my normal
preallocation of the main variables.
On TSO/MVS/ZOS I generally had additional variables such as
FILE1LRECL FILE1BLKSIZE etc.
My ALLOC statement generally allocated the file to an appropriate
ddname such as FILE1DD
This entire process allowed me to reuse code without having to think
about it too much as well...
Obviously you change the "1" in each of these variables to an
appropriate file number.
5. In the case of an APACHE server, there is a "rexxmod" which can be
used to allow full support of web pages WRITTEN in Rexx. Check
Sourceforge.net for details.
6. While I have never done so, I suspect that rexx can be used as a
CGI language - and this might be where the CR/LF of SAY might be a
small problem.
/s/ Bill Turner, wb4alm
Post by Bill Schoen
CGI REXX scripts do work.
I just had the need to do some specialized search/view/update/create
for github issues.
Scripting CGIs along with the REXX API to the web enablement
toolkit, especially for json parsing is awesome.
It only took about an hour to get something very basic going for my
first CGI, but days to learn enough HTML to make it pretty.
The REXX CGI samples use SAY for output. I suggest using charout()
if you might be sending log html strings.
SAY can insert newline characters in unexpected spots.
Bill Schoen
snip...
CGI scripts would be awesome to explore, but I don't have the time.....B-)
Btw, do REXX CGI scripts work with Apache???
...snip
R;
Rob Hamilton
Sr. System Engineer
Chemical Abstracts Service
--------------------------------------------------------------------
-- For TSO-REXX subscribe / signoff / archive access instructions,
---------------------------------------------------------------------
- For TSO-REXX subscribe / signoff / archive access instructions,
----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions, send
--
OREXXMan

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions, send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX

----------------------------------------------------------------------
For TSO-REXX subscribe / signoff / archive access instructions,
send email to ***@VM.MARIST.EDU with the message: INFO TSO-REXX
Bass, Walter W
2017-04-14 22:10:31 UTC
Permalink
Raw Message
I've written a full screen WYSIWYG BMS map editor in REXX. Having come from an old IDMS/ADS-O shop, I missed the map editor, OLM.

One day as an exercise for displaying panels with custom highlighting in REXX I started slinging some code. After I got a little deep into creating custom panels on the fly, I decided to see how far I could go to displaying a BMS map from the source code. Turns out I could go pretty far. Then I ran into issues that I couldn't solve without using TPUT and TGET. By that time I had enough code written to make it worth the effort to turn it into something real. I added an assembler stub to handle the TPUT/TGET and ended up with a very usable editor.

I'm willing to share the code with anyone that is interested. It is all self-contained within five REXX members. No panels, messages, tables, etc. needed.

 ____________________________

Walter (Bill) Bass | Optum
Senior Applications Development, Optum Tech App Srvcs Grp - 630
2 Independence Pt., Ste. 100, Greenville, SC 29615, USA
www.optum.com


-----Original Message-----
From: TSO REXX Discussion List [mailto:TSO-***@VM.MARIST.EDU] On Behalf Of John McKown
Sent: Wednesday, April 12, 2017 9:50 AM
To: TSO-***@VM.MARIST.EDU
Subject: [TSO-REXX] curious: Uses of REXX.

<SNIP>
But I wondering if REXX
on z/OS is really used much beyond ISPF macros and the occasional TSO
command
<ENDSNIP>


This e-mail, including attachments, may include confidential and/or
proprietary information, and may be used only by the person or entity
to which it is addressed. If the reader of this e-mail is not the intended
recipient or his or her authorized agent, the reader is hereby notified
that any dissemination, distribution or copying of this e-mail is
prohibited. If you have received this e-mail in error, please notify the
sender by replying to this message and delete this e-mail immediately.
Loading...