Fix daily resetting value display like PV Daily Energy in Influxdb / Grafana?

I’m trying to fix a situation where I have nightly resetting values like PV energy produced per day that look odd because they don’t update after 8 PM. This makes the graph look bad with diagonal lines.

If a sensor value in HA has not changed, is there a way to force a way to force write it to the db just before midnight (11:59 PM)?

I’d like it to look more like this where the lines continue to midnight and then reset to zero.

Grafana allows you to choose how to interpolate between data points. You want to choose step after

You don’t want to add superfluous data points to fix a visualization issue.

Thanks, this solved the diagonal lines problem! …but now it’s made all of the line’s steps apparent. Is there a way to have the smooth line with the step after interpolation?

Not that I’m aware of. Maybe there is some grafana method to pick out and plot the max value of the day (from the start of the day to the current time on the X-axis).

For most things that reset daily, I’m looking at plots (column charts) of daily totals rather than values within a single day. If I want to look within a single day, I’ll use a column chart of hourly totals. And I do this with HA instead of grafana since HA handles it so easily.