Well, I need a help to query certain values in a document.
I have a collection in the mongo that follows this structure, including this is the document I can get and find: link
The find this easy I find document without problems using the criterion: "pages": 32
The problem I have is to display only the array items that are in objects, so this is what I expect to return from the query for "pages": 32:
{
"book": [
{
"pages": 32,
"title": "a"
},
{
"pages": 32,
"title": "c"
},
{
"pages": 32,
"title": "d"
}
]
}
Can anyone give me the path to stones, tips or suggestions?