Can't handle right scaling (aggregation problem) from kWh in y-axis

Hey there,

i am using Grafana 9.3.2 on a raspberry with nodered and for reading my energymeters.

I receive data and can show them in a time series panel. No problem so far. But i have issues with the scaling. on the graph, the unit is kW as a momentary power. With the “group by” setting, i can change the data on the y-axis. If i edit it to 1 hour the values on the y-axis are plausible. If i reduce the “group by” setting, the value get’s lower.

Here the scale is not right.

I expect the scale to look like this.

If i “group by” to 1 hour, the scale looks good, but then i only have one datapoint per hour. I would prefer to have one datapoint every 15 minutes (as it is set now).

A “stat” panel, which gives me a text for a total day has the correct value, so i am sure, that the raw data is correct. I think i made a misstake in the query, but i don’t get it.

I hope the problem is well described, that is a little tricky for me in english, sorry :wink:

Thanks for any help!

Here is the query, if that may helps: