The INITIATE Statement (Report Writer)

The INITIATE statement causes the RWCS to begin the processing of a report.

General Format


Syntax for the INITIATE statement

Syntax Rules

  1. Report-name-1 must be defined by a report description entry in the report section of the Data Division.

General Rules

  1. The INITIATE statement performs the following initialization functions for each named report:
    1. All sum counters are set to zero.
    2. LINE-COUNTER is set to zero.
    3. PAGE-COUNTER is set to one.
  2. The INITIATE statement does not place the file associated with the report in the open mode; therefore, an OPEN statement with either the OUTPUT phrase or the EXTEND phrase for the file must be executed prior to the execution of the INITIATE statement.
  3. A subsequent INITIATE statement for report-name-1 must not be executed unless an intervening TERMINATE statement has been executed for report-name-1.
  4. If more than one report-name is specified in an INITIATE statement, the result of executing this INITIATE statement is the same as if a separate INITIATE statement had been written for each report-name in the same order as specified in the INITIATE statement.