for some time I have used this query to get the last value from a measurement:
from(bucket:"iobroker/global") |> range(start:-8d) |> filter(fn:(r) => r._measurement == "gaszaehler.0.absolute") |> last()
However, this doesn’t work if the last value (or any others) have tags. Then I get a result for each combination of tags.
But I want to ignore all tags and just get the newest entry in the measurement, like this in SQL:
SELECT timestamp, value FROM measurement ORDER BY timestamp DESC LIMIT 1