Enform Plus Reference Manual

Enform Plus Language Elements
Enform Plus Reference Manual422684-001
3-12
Aggregates
AVG
is a predefined Enform Plus aggregate that computes an average value for a set of
numbers or expressions.
COUNT
is a predefined Enform Plus aggregate that tallies the occurrences of a field defined
as either numeric or alphanumeric.
MAX
is a predefined Enform Plus aggregate that finds the highest number in a set of
numbers or expressions, or finds the alphanumeric string with the highest value
based on the ASCII collating sequence.
MIN
is a predefined Enform Plus aggregate that either finds the lowest number in a set of
numbers or expressions or finds the alphanumeric string with the lowest value based
on the ASCII collating sequence.
SUM
is a predefined Enform Plus aggregate that totals a set of numbers or expressions.
user-aggregate
is the name of an aggregate defined by a DECLARE statement. (See page 4-9.)
field-name
is the name of a database field.
expression
is a arithmetic or IF/THEN/ELSE expression (explained on page 3-26.)
over-item
is a field used to sort and group the records over which the aggregate is processed.
For a target aggregate, over-item must be a by-item (the name of a field
modified by a BY or BY DESC clause). For a qualification aggregate, over-item
can be any field name.
OVER ALL
defines the range of the aggregate operation as over all the values specified.
OVER
defines a range for the aggregate operations. The aggregate operation takes place
only over the specified over-item. The operation yields one aggregate value for
each unique value of over-item.