Modifying a data entry point (is that even the correct term?)

Morning all, i’m not sure if this is in the correct place, but I’m using influxdb attached to home assistant via dockers, I have historical data that can be graffed with grafana using the command:

SELECT distinct("power") FROM "device_tracker.thundercat" WHERE ("domain" = 'device_tracker' AND "entity_id" = 'thundercat') AND $timeFilter GROUP BY time($__interval) fill(linear)

however after rebuilding HA the tracker battery info is now appearing when i use this query:

SELECT distinct("power") FROM "state" WHERE ("domain" = 'device_tracker' AND "entity_id" = 'thundercat') AND $timeFilter GROUP BY time($__interval) fill(linear)

Is it possible to move the historical data to be queried with the new entry? Thanks in advance, and sorry if this is in the wrong place.