␡
- Inserting Data
- Reading Data
- Updating Data
- Removing Data
- Conclusion
Like this article? We recommend
Removing Data
To remove data, you can use the remove() method. A simple remove query is the following:
db.testData.remove({})
The query above removes all documents from the testData collection. To remove documents based on a condition, do the following:
db.testData.remove({name : “Jacks Teller”, age: 37})