sum()

sum(col) returns the sum of the values in the provided column.

Non-numeric values are ignored.

Returns

A table with one row and one column, called @q.sum.

Example

Compute the number of bytes received in the checkout_api service, aggregated by host.

kubernetes.container_name: "checkout_api"
| stats sum(log.%kv.bytes) by host

Last updated