boundaries.wednesday() function

boundaries.wednesday() returns a record with start and stop boundary timestamps for last Wednesday.

Last Wednesday is relative to now(). If today is Wednesday, the function returns boundaries for the previous Wednesday.

Function type signature
() => {stop: time, start: time}
For more information, see Function type signatures.


Query data collected last Wednesday

import "date/boundaries"

day = boundaries.wednesday()

from(bucket: "example-bucket")
    |> range(start: day.start, stop: day.stop)

Was this page helpful?

Thank you for your feedback!

Upgrade to InfluxDB Cloud or InfluxDB 2.0!

InfluxDB Cloud and InfluxDB OSS 2.0 ready for production.