title |
description |
menu |
weight |
aliases |
related |
flux/v0.x/tags |
introduced |
today() function |
The `today()` function returns the `now()` timestamp truncated to the day unit.
|
flux_0_x_ref |
name |
parent |
today |
universe |
|
|
102 |
/influxdb/v2.0/reference/flux/stdlib/built-in/misc/today/ |
/influxdb/cloud/reference/flux/stdlib/built-in/misc/today/ |
|
/flux/v0.x/stdlib/universe/now/ |
/flux/v0.x/stdlib/date/truncate/ |
/flux/v0.x/stdlib/system/time/ |
|
|
0.116.0 |
The today()
function returns the now()
timestamp truncated to the day unit.
today()
Examples
Return a timestamp representing today
option now = () => 2021-01-01T13:45:28Z
today()
// Returns 2021-01-01T00:00:00.000000000Z
Query data from today
from(bucket: "example-bucket")
|> range(start: today())