In my web scraping project i need to move previous day scraped data from mongo_collection
to mongo_his_collection
I am using this query to move data
for record in collection.find():
his_collection.insert(record)
collection.remove()
It works fine but sometimes it break when MongoDB collection
contain above 10k rows
Suggest me some optimized query which will take less resources and do the same task