SUM, MIN, and MAX aggregate numeric values. AND, OR, and XOR fold values as 64-bit integers, truncating fractions. These operations skip non-numeric values. USED counts occupied slots. MATCH counts values equal to the supplied value.
Arguments
string
required
The array key.
number | string
required
The first index of the inclusive range.
number | string
required
The last index of the inclusive range.
ArOpOperation<TData>
required
The reduction to apply. See the operations below.
"SUM", "MIN", "MAX", "AND", "OR", "XOR", or "USED" (lowercase is also accepted). For equality matching, pass { match: value } as the operation.
Response
The numeric aggregate, or
null (TypeScript) / None (Python) if no values can be used. USED and MATCH return zero for an empty range.