Details
Description
Reference manual page for delete command - https://docs.mongodb.com/manual/reference/command/delete/ - says that comment field should be inside of deletes array. However, comment has to be a top level field.
test> db.runCommand({"delete": "collection0", "deletes": [{"q": {}, "limit": 1, "comment": "test"}]})
|
MongoServerError: BSON field 'delete.deletes.comment' is an unknown field.
|
|
test> db.runCommand({"delete": "collection0", "deletes": [{"q": {}, "limit": 1}], "comment": "test"})
|
{
|
n: 0,
|
electionId: ObjectId("7fffffff0000000000000004"),
|
opTime: { ts: Timestamp({ t: 1641910276, i: 1 }), t: Long("4") },
|
ok: 1,
|
'$clusterTime': {
|
clusterTime: Timestamp({ t: 1641910276, i: 1 }),
|
signature: {
|
hash: Binary(Buffer.from("0000000000000000000000000000000000000000", "hex"), 0),
|
keyId: Long("0")
|
}
|
},
|
operationTime: Timestamp({ t: 1641910276, i: 1 })
|
}
|