sum
sum — aggregate function to calculate the sum of a range of values.
DESCRIPTION
This function computes a value for each record from the specified column of a base table, and returns the sum of those values.
When the field type is timestamp, summing members of the field follows the rules for adding timestamps as shown in the table in timestamp Data Type. That is, you cannot sum an aggregate of two or more absolute timestamps. However, you can sum an aggregate field composed of all interval timestamps, or one composed of exactly one absolute timestamp plus one or more interval timestamps.
The argument expr
must include the name of
a column in a LiveView table, where that column's data type is int, long, double, or
timestamp. The returned value is of the same data type.
When the field type is timestamp, summing members of the field follows the rules for adding timestamps as shown in the table in timestamp Data Type. That is, you cannot sum an aggregate of two or more absolute timestamps. However, you can sum an aggregate field composed of all interval timestamps, or one composed of exactly one absolute timestamp plus one or more interval timestamps.
SEE ALSO
This LiveView aggregate function is based on the sum aggregate function in the StreamBase expression language.