Data Specifications

Data specifications supply input to a program that expects input from a card reader file during execution; that is, a file declared in the program as being of kind READER.

A data specification can also be used in place of any input file the program reads by file‑equating the title of the input file to the title of the data specification in the WFL job, and by declaring the type of input file to READER.

Two kinds of data specifications are available:

  • Local data specifications

  • Global data specifications

A global data specification can be declared at the start of a job, and can be used by more than one task.

Example

The following example illustrates a job that uses a global data specification:

?BEGIN JOB INTREF;
DATA INPUT            % Begin global data specification
          7
         11
?                     % End global data specification
  RUN (WENDY)OBJECT/INT/REF;
    FILE TERMIN(TITLE=INPUT,KIND=READER); % Causes the program to
                                          % read from the global
                                          % data specification INPUT
                                          % instead of the file
                                          % TERMIN.
?END JOB.