Function: COUNT_TOTAL
Syntax: COUNT_TOTAL()
or COUNT_TOTAL(field)
Description: Counts the total number of records across all groupings (i.e. all records retrieved across the union of all dimensions). When a field is provided the function counts the number of records where the field value is not null.
The COUNT_TOTAL
aggregator may be used in custom formulas to create relative ratios and ponderate the result of other aggregators such as COUNT
or COUNT_CUMULATIVE
.
Sample usage:
COUNT_TOTAL()
returns the total number of records across all groups.COUNT_TOTAL(due_on)
returns the total number of records wheredue_on
is not null.ROUND(COUNT() / COUNT_TOTAL(), 2) * 100
returns the percentage that eachCOUNT
represents in comparison to the grand total.