Documentation

experimental.sum() function

Flux 0.107.0+

The experimental.sum() function is subject to change at any time. By using this function, you accept the risks of experimental functions.

The experimental.sum() function computes the sum of non-null values in the _value column for each input table. experimental.sum() is an aggregate function.

import "experimental"

experimental.sum()

Parameters

tables

Input data. Default is piped-forward data (<-).

Examples

import "experimental"

from(bucket: "example-bucket")
  |> range(start: -5m)
  |> filter(fn: (r) =>
    r._measurement == "example-measurement" and
    r._field == "example-field"
  )
  |> experimental.sum()

Upgrade to InfluxDB Cloud or InfluxDB 2.0!

InfluxDB Cloud and InfluxDB OSS 2.0 ready for production.