Running an Exec in the TSO/E Address Space - IBM-REXX

You can invoke a REXX exec in the TSO/E address space in several ways. To invoke an exec in TSO/E foreground, use the TSO/E EXEC command processor to either implicitly or explicitly invoke the exec and you must have ddname GRXBIMG allocated. z/OS TSO/E REXX User’s Guide describes how to invoke an exec in TSO/E foreground.

You can run a REXX exec in TSO/E background. In the JCL, specify IKJEFT01 as the program name (PGM= ) on the JCL EXEC statement. On the EXEC statement, specify the member name of the exec and any arguments in the PARM field. For example, to execute an exec called TEST4 that is in data set USERID.MYREXX.EXEC, use the following JCL:


You can also invoke an exec implicitly or explicitly in the input stream of the SYSTSIN DD statement.


From a program that is written in a high-level programming language, you can use the TSO service facility to invoke the TSO/E EXEC command to process a REXX exec. z/OS TSO/E Programming Services describes the TSO service facility in detail.

You can also invoke a REXX exec from an application program using the exec processing routines IRXJCL and IRXEXEC.Although IRXJCL and IRXEXEC are primarily used in non-TSO/E address spaces, they are programming interfaces to the language processor that you can use to run an exec in any address space, including TSO/E. For example, in an assembler or PL/I program, you could invoke IRXJCL or IRXEXEC to process a REXX exec.

The IRXEXEC routine gives you more flexibility in processing an exec.For example, if you want to preload an exec in storage and then process the preloaded exec, you can use IRXEXEC. “Exec Processing Routines – IRXJCL and IRXEXEC” on page 261 describes the IRXJCL and IRXEXEC interfaces in detail.

Note: You cannot invoke a REXX exec as authorized in either the foreground or the background.

All rights reserved © 2020 Wisdom IT Services India Pvt. Ltd Protection Status