I have InfluxDB on Home Assistant.
I needed to delete some not valid data from InfluxDB and I did it by copying the measurement :
SELECT * INTO metrics_clean FROM metrics WHERE value!=0
After that I deleted the old measurement:
DROP measurement metrics.
And than copied the new measurement to the old name:
SELECT * INTO metrics FROM metrics_clean
But after all this , I don’t see new values of this measurement saved in InfluxDB from Home assistant.
Other measurements continue to work properly.
Update : I think maybe because it was created by me , the Home Assistant can’t to write to the MEASURMENT.
I backed up the data by SELECT * INTO metrics FROM metrics_backup
And deleted the "metrics " by DROP measurement metrics.
And after that I saw that the MEASURMENT was created by itself and the data begun to be written in InfluxDB.
Than I copied the metrics_backup back into the exsisted metrics.
But after the copying I saw that the all date turned into mush, all ‘fields’ was duplicated and I paid attention , after several copies of the metrics , the MEASURMENT looks garbadge.
How to copy without field’s duplications and can I repair the MEASUREMENT ?