What is the easiest way to delete all documents in the container in cosmosdb with mongodb api? Can I do it directly from AZURE portal?
Asked
Active
Viewed 480 times
1 Answers
1
Yes,
(1) by deleting existing container and recreating a new container with same name
(2) by setting the TTL. You can se the time to live of the container to 1 second. ETA for the deletion of documents will be depending on the number of documents and the throughput of Cosmos DB account.
https://learn.microsoft.com/en-us/azure/cosmos-db/mongodb/mongodb-time-to-live

Sajeetharan
- 216,225
- 63
- 350
- 396