Statistics sum, suddenly very large value

I have a sensor for total production of electricity from my Goodwe inverter. This has worked well for 2 years. Now I have a problem with really strange values, see this extract from the statistics table:

|state  |sum               |
|28868.2| 14549803.40000047|
|28855.1| 14549790.30000047|
|28828.3|           28828.3|
|28819.2|           28819.2|
|28810.7|           28810.7|
|28802.3|           28802.3|
|28796.4|           28796.4|

I’ve tried to fix this by setting the sum to the value of state (I don’t this is correct but it is good enough for me). BUT, the big values always comes back after a statistics run.

What is happening here, and what can I do about it? Set one row to a big negative value?

Do not manipulate the statistics data tables directly.

Go to Developer Tools → Statistics. Click the ramp icon next to your entity. Find the time the erroneous reading occurred and edit it there.

Also look at the history graph of the entity to see what happened.