Differences from Extract Phase

CA Culprit interprets field references made during the output phase of processing differently from field references made during the extract phase of processing, as follows:
idmscu
CA Culprit interprets field references made during the output phase of processing differently from field references made during the extract phase of processing, as follows:
  • References to numeric fields can refer to column totals and values of a sort key, as well as to values obtained from process operations performed in type 8 procedure logic.
  • If a subscripted field is referenced on a SORT or type 5 edit parameter, the subscript is considered part of the field name in the output phase. Otherwise, the subscript is interpreted as a pointer to an occurrence of the multiply-occurring work field. In the extract phase, the subscript always acts as a pointer to a particular occurrence of a multiply-occurring field.
Actions During Extract Phase
During the extract phase, a TAKE or RELS instruction in type 7 procedure logic causes the following types of records to be written to the extracted items and statistics file:
  • Detail records
    , which contain a composite sort key and unedited data. These records are used by type 5 edit parameters to generate the detail lines for the reports.
  • HEAD records
    , which contain a composite sort key and the current values of fields that are not referenced on the SORT parameter but are referenced on a type 4 edit parameter. These records are generated when HEAD is a specified result action in type 7 procedure logic processed during the extract phase.
Actions During Output Phase
The output phase reads the sorted extracted items file and the unsorted extracted items file. During the output phase, CA Culprit performs the following tasks:
  • Report headings, if any, are output at the start of the report, following a control break defined with break code 1 (signifying a new page) or after the lines-per-page count is reached.
  • Totals are maintained for each numeric field referenced on a type 5 edit parameter.
  • Values from HEAD records are saved for use in header lines.
  • Control breaks execute when a sort key changes, beginning with the lowest level control break (that is, LEVL=1) and ending with the break associated with the current value of LEVL.
    The following functions are performed at each control break:
    • LEVL is set to the appropriate value.
    • Processing control passes to type 8 procedure logic.
    • Total lines defined by type 6 edit parameters or automatic total lines are output.
    • Spacing associated with the current break code is performed.
Field references during the output phase fall into two categories: field references made on type 4 edit parameters, and field references made on type 6 edit parameters and on type 8 process parameters. The manner in which these references are resolved during the output phase is described as follows.