0

Tryin to delete this document from my collection:

db.users.find({"dref._id": "USER_ONE", "dref.age" : 23, "school": "BRHS"})

When I search it using the find, i get it. I'm trying to use this for delete it:

db.users.deleteOne({"dref._id": "USER_ONE", "dref.age" : 23, "school": "BRHS"})

What am i doing wrong?

Fragola 86
  • 59
  • 1
  • 4
  • Any error message returned ? – ray Nov 17 '21 at 12:27
  • nope, just 0 records deleted – Fragola 86 Nov 18 '21 at 13:31
  • We probably need more context to see what's going on. Are you using a read-only account to access? or are you doing the operation on a secondary replica? These are 2 likely reasons that you cannot do a delete but you can read/find the document – ray Nov 19 '21 at 07:55

0 Answers0