I have an old time series collection called “series”. It is stored in the db “data”. Now, I would like to move this collection to the db “data_old”, as I don’t need it in “data” anymore. First, I tried with the rename command, where one can simply rename from “data.series” to “data_old.series” for standard collections. However, this is not supported for timeseries collections and therefore raises an error (MongoServerError: cannot rename view: data.series).
So my question is what would be the best way to move the timeseries collection from data to data_old? The most stupid way that I can come up with right now is creating a new timeseries collection “series” in data_old and copying all the documents from the one in data to the one in data_old, then deleting the one in data. But is there a faster and more elegant way?
Thanks, best, JZ