Invalid query result in mongoose while querying an array of embedded documents

17 views
Skip to first unread message

Ammar Lakho

unread,
Oct 2, 2022, 12:27:29 PM10/2/22
to Mongoose Node.JS ODM
I am facing a discrepancy in query results between mongoose and the mongosh terminal in MongoDB Compass. The problem seems to be in the mongoose result. I have a user document with the following schema:

Reply all
Reply to author
Forward
0 new messages