I\'m looking at MongoDB\'s documentation on the $ and $elemMatch projections. I\'m trying to figure out how to return only a subset of a projection array\'s fields, but I canno
Are you specifically trying to do this without using aggregate?
db.test.aggregate([{$unwind:"$array"}, {$match:{"array.key":1}}, {$project:{"array.name":1, extra:1}}])