I have a mongoose schema like -
db.foo.insert({one:'a',friends:[{two:'b',three:'c'},{two:'d',three:'e'},{two:'f',three:'G'}]})
now what i want is two retrieve only the 'two' part of friends array
that is I want to find an array of all the values of two in each object in friends array
Is such a projection possible in mongodb where in the output looks like -
['b','d','f']