使用如下文档:
{
"obj1" : [
{
"name" : "blue",
"count" : 4
},
{
"name" : "green",
"count" : 6
}
]
}
是否可以查询obj1.name = "blue"
以获取数组的匹配元素,而不是文档?:
{
"name" : "blue",
"count" : 4
}
提前致谢!