switching form influxql to flux I have a problem with the bar-gauge axis. I’m using the InfluxDB v2.6.1 and Grafana 9.3.6.
I want to display the daily total gas consumption. My Viessmann heater provides in the api values for the last 8 days I want to consume. I called the data points V-Gas-total.day01…V-Gas-total.day08 in addition there is also a datapoint for the last timestamp V-Gas-total.readDate.
Using the following flux code, the data I get is fine, but it shows the _measurement V-Gas-total.day0X and I want to user the data point V-Gas-total.readDate or the date of today to calculate and show the day name (Mon, Tues, etc).
import "timezone" option location = timezone.location(name: "Europe/Berlin") from(bucket: "iobroker") |> range(start: -7d) |> filter(fn: (r) => r["_measurement"] =~ /.-Gas-total.day+/) |> filter(fn: (r) => r["_field"] == "value") |> last()
The result currently looks like this:
Any idea how I could resolve this?