📜  通过数组键查询 mongo - 任何代码示例

📅  最后修改于: 2022-03-11 14:58:22.378000             🧑  作者: Mango

代码示例1
db.test.find(
    {"shapes.color": "red"}, 
    {_id: 0, shapes: {$elemMatch: {color: "red"}}});