What is REXX ?

What is REXX ?

  • Restructured EXtended eXecutor language
  • High Level Programming Language
  • Has extensive mathematical capabilities
  • Easy to Learn and Easy to maintain
  • Good for Automation

 



 

Advantages of REXX:

  • Free format Programming Language
  • Readability
  • It is not Case sensitive
  • Interpreted Language
  • Convenient built-in functions
  • Powerful debugging capabilities
  • Extensive parsing capabilities
  • Can be used in various platforms. E.g. MVS, DOS, AS400

 


REXX usage

  • Execute TSO commands
  • Execute ISPF commands
  • Execute JCL
  • Can Manipulate/Handle Datasets
  • Can create Front End screens like CICS




 

How to Write a REXX

  1. Rexx programs are called EXEC
  2. Allocate a dataset or PDS to write rexx programs
  3. Begin an exec with a comment line which includes the word REXX.
  4. Comment line in REXX begins with /* and ends with */
  5. Placement of comments and instructions in one line is possible.
  6. Requires one or more blank to separate arguments.
  7. Arguments can be in any case.
  8. To combine related statements use a semi colon to separate them.
  9. To continue a statement, other than a comment on next line use comma to indicate continuation.

Writing a REXX

  • Basic Terminal Input/Output :
    To display information on screen, use keyword “SAY”
    To retrieve user inputs, use keyword “PULL”
  • Dynamic Typing:
    In Rexx there is no need to define variables explicitly.
    Specific variable types are determined dynamically depending on the operations.
    e.g. String manipulation, arithmetic operation etc.
    Rexx views all data as alphanumeric character strings.