Previous Topic: GROUP Statement

Next Topic: Grouping Feature Example 1


GROUPC Statement

The GROUPC statement is optional. It is used in conjunction with the GROUP statement for a given report. Whereas the GROUP statement defines which fields in the accounting record are to be used in the grouping feature, the GROUPC statement supplies the range of values to be used in a compare instruction to qualify the record. Multiple GROUPC statements may be required for a given report in order to provide many value ranges to qualify each accounting record.

The definition indicator on the GROUPC statement specifies which definition of the GROUP statement is applicable. Therefore, the definition indicator may be 1 to 6, relating to the proper definition number on the GROUP statement.

The lower and upper limiting criteria on the GROUPC statement provide the actual range of values which are compared against the corresponding value in the accounting record to qualify the record.

The range values must be left-justified with trailing blanks when needed. If the upper limiting criteria is the same as the lower limiting criteria, it may be omitted.

The group code on the GROUPC statement is a one-character code that is placed in any accounting record that is selected according to the value ranges. The group code can subsequently be used as a sort control field via the SORT statement to provide totals for the different groups of accounting records selected by the grouping feature.

Note that positions 296 through 298 and positions 438 through 440 in the Basic Accounting Table correspond to the group codes for the six definitions as defined by the definition indicator on the GROUPC statement.

The CPU identification code on the GROUPC statement allows you to easily change the CPU identification of any accounting record for further processing. In this way, qualified records can be assigned different CPU identification codes corresponding to multiple RATE statements for a given report. Identified record groups may then use a different accounting algorithm than other accounting records.

A blank CPU identification code on the GROUPC statement indicates that no change in the record CPU Identification is desired.

The following examples illustrate some typical uses and combinations of the GROUP and GROUPC statements.