Help switching back from google cloud mysql to intern SQLite database for recorder


I need your help. I use google cloud mysql for the database in Homeassistant for more than a year.
Now I want to go back to the SQLite internal database in SD-Card but keep all the data from the old cloud database.

Can anyone tell me how to transfer the data without losing the stats?

Best wishes,