Deleting Documents
π deleteOne()
Deletes the first document that matches the condition.
db.reviews.deleteOne({"_id": ObjectID("56458bggfjhg")})π deleteMany()
Deletes all the documents that match the condition.
db.reviews.deleteMany({"reviewer_id": 759723314})Last updated
Was this helpful?