Details
-
Bug
-
Resolution: Done
-
Minor - P4
-
None
-
None
-
None
-
*Location*: https://docs.mongodb.com/manual/reference/method/db.collection.findOneAndUpdate/
*User-Agent*: Mozilla/5.0 (Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; MS-RTC LM 8; .NET4.0E; InfoPath.3; rv:11.0) like Gecko
*Screen Resolution*: 1366 x 768
*Location*: https://docs.mongodb.com/manual/reference/method/db.collection.findOneAndUpdate/ *User-Agent*: Mozilla/5.0 (Windows NT 6.1; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; MS-RTC LM 8; .NET4.0E; InfoPath.3; rv:11.0) like Gecko *Screen Resolution*: 1366 x 768
Description
In the example provided for 'Update document with Upsert', return document seems to be wrong -
Returned new document contains "_id" : 5239 whereas the _id field is not present either in query document or in update document. In this case it should contain an objectId assigned by mongod or the driver.