REXX
A readable scripting language used across the mainframe for automation, tooling and quick one-off tasks.
Also written Restructured Extended Executor
REXX is the scripting language of the mainframe. Where COBOL writes the business applications, REXX writes the tools around them: automation, housekeeping, reporting, testing aids and the small utilities that make a team's day easier.
It was designed to be easy to read and forgiving to write. Variables need no declaration, types are handled automatically, and arithmetic is decimal and accurate. The syntax is close to plain instructions, and a useful script can be a dozen lines.
Its real power on z/OS is the ability to issue commands to the environment it runs in. A REXX exec can issue TSO commands, drive ISPF services, submit jobs, read and write datasets, and inspect the results, checking what came back and deciding what to do next. That makes it the natural glue between things.
It runs interactively rather than being compiled, so the write-run-fix loop is fast, which is exactly what you want for the kind of work it is used for.
It is also an excellent first language on the platform, because you can do something useful within minutes.
Related terms
- REXX execA REXX program, stored as a member in a library and run by name from TSO or ISPF.
- PARSEREXX's instruction for pulling a string apart into pieces, by position, by delimiter or by pattern.
- Stem variableREXX's array, a variable with a dot in its name used to hold a list such as the lines of a file.
- TSO commandA command typed at a TSO prompt or on an ISPF command line to ask the system to do something directly.
- ISPFThe full-screen, menu-driven workbench most people use to do their day-to-day work on z/OS.