Energy Card: How to delete/purge records from an "early" misconfiguration period

Understanding the Energy Card

I started exploring the data with SQLite Web.

  • Is there an “overall” explanation around, how the recorder works and how statistics are calculated (and recorded)? I couldn’t find such obvious information myself.
  • Is the flow like this? states (like snapshot values, real “recording”) → statistics_short_term (5 min) → statistics (1 h)
  • Because in the statistics_short_term
  • What does the Energy Card pick up of these? I couldn’t see a metadata_id that looks like originating from the dashboard directly. Has the Energy Card any influence on the mechanism statesstatistics_short_term?
  • If I would be able to find the exact “wrong” values in states and replace or delete them, would statistics_short_term and statistics be recalculated?

DB and Recorder - Home Assistant stuff:

As I started looking closer to this DB stuff and reading some posts like this Energy dashboard not showing historical data - #5 by wouter_klaassen, etc.

Should I start a new thread for the DB migration part (MariaDB outside HA)?