Cum Clause; Cum With Over All; Cum With Over - Tandem ENFORM 058057 Reference Manual

Data management library
Table of Contents

Advertisement

CUM Clause

The CUM clause allows you to specify printing of a running total for a numeric
target-item either for all the instances of the target-item or for the instances of the
target-item grouped within the each value of a by-item. The syntax of the CUM
clause is:
target-item
target-item
by-item

CUM with OVER ALL

When you specify the CUM OVER ALL clause, ENFORM prints a running total in
place of each value of the numeric target-item. When you specify only CUM, ENFORM
assumes CUM OVER ALL.

CUM with OVER

When you specify the CUM OVER by-item clause, ENFORM prints a running total for
the instances of the numeric target-item within the by-item in place of the value of the
numeric target-item. The by-item must be previously defined by a BY or BY DESC
clause. The running total begins anew each time the by-item value changes. The
following example prints the running total of all parts for each location:
058057 Tandem Computers Incorporated
OVER ALL
[
CUM
OVER by-item
is a record name, a field name, a numeric literal, a predefined aggregate, a user
aggregate, an arithmetic expression, an IF/THEN/ELSE expression, a user
variable, or a System Variable clause. The data type of a target-item used in a CUM
clause must be numeric.
is the name of a field grouped by a BY or BY DESC clause.
LIST BY location,
partnum,
inventory,
inventory CUM OVER location;
Part
LOCATION
Number
--------
------
L98
5103
5502
V66
6603
...
...
]
CUM
INVENTORY
INVENTORY
---------
---------
8
6
14
40
40
...
...
Clauses
CUM Clause
8
5–35

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Enform

Table of Contents