Weird cost values in Energy / Photovoltaik module after switching to MySQL database backend

After changing my Home Assistant installation’s database backend from SQLite to MySQL, my “cost” values in the Energy Dashboard have become randomly high:

I already tried reconfiguring the Energy dashboard using the right €/kWh values, however it didn’t change.

I have no idea what could trigger this behavior. Does anyone have any experience there or is able to help me out?
Best, taiBsu