Chapter 2. Writing and Running a REXX Exec
This chapter introduces execs and their syntax, describes the steps involved in
writing and running an exec, and explains concepts you need to understand to
avoid common problems.
Before You Begin
Before you can write a REXX program, called an exec, you need to create a data
set to contain the exec. The data set can be either sequential or partitioned, but if
you plan to create more than one exec, it is easier to create a REXX library as a
partitioned data set (PDS) with execs as members.
To create a PDS, allocate a data set with your prefix (usually your user ID) as the
first qualifier, any name as the second qualifier, and preferably "exec" as the third
qualifier. You can allocate the PDS with the Utilities option in ISPF/PDF or with the
© Copyright IBM Corp. 1988, 2001
Keyword . . . . . . . . . . . . . . . . . . . . . . . . . 13
Assignment . . . . . . . . . . . . . . . . . . . . . . . . 13
Label . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Null . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Command. . . . . . . . . . . . . . . . . . . . . . . . . 14
. . . . . . . . . . . . . . . . . . . 10
. . . . . . . . . . . . 14
. . . . . . . . . . . . . . . . . . . 16
. . . . . . . . . . . . . . . . . . . 17
24
7