Skip to main content

sumMapWithOverflow

Introduced in: v20.1.0 Totals a value array according to the keys specified in the key array. Returns a tuple of two arrays: keys in sorted order, and values summed for the corresponding keys. It differs from the sumMap function in that it does summation with overflow - i.e. returns the same data type for the summation as the argument data type.
  • Passing a tuple of key and value arrays is identical to passing an array of keys and an array of values.
  • The number of elements in key and value must be the same for each row that is totaled.
Syntax
Arguments
  • key — Array of keys. Array
  • value — Array of values. Array
Returned value Returns a tuple of two arrays: keys in sorted order, and values summed for the corresponding keys. Tuple(Array, Array) Examples Array syntax demonstrating overflow behavior
Query
Response
Tuple syntax with same result
Query
Response
See Also