Answer the question
In order to leave comments, you need to log in
In MongoDB, is it possible to query a property (individual value) of a document hierarchy only by querying the whole document, or is it possible in parts, with any nesting level?
In MongoDB, is it possible to query a property (individual value) of a document hierarchy only by querying the whole document, or is it possible in parts, with any level of nesting?
Answer the question
In order to leave comments, you need to log in
Да, можно.
При записях в базе вида:
{
"_id": ObjectId("530824b95f44eac1068b45c8"),
"accs": {
"boss": {
"name": "Stefan",
"roles": ["admin", "ceo"]
}
},
"ingener": {
"name": "Jhon",
"roles": ["user", "staff"]
}
}
{
"accs": {
"boss": {
"roles": ["ceo"]
}
}
}
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question