I'm having the following document structure:
{
  _id: 123,
  name: 'My playlist',
  videos:[
   {videoId:1},
   {videoId:2},
   {videoId:3}]
}
Now I want to do a $lookup in the video collection to get all video data. At the end, I need a data structure like this:
{
  _id: 123,
  name: 'My playlist',
  videos:[
   {videoId:1, videoDetails:[{_id:1, title:'My funny video', views:123}]},
   {videoId:2, videoDetails:[{_id:2, title:'My new video', views:1234}]},
   {videoId:3, videoDetails:[{_id:3, title:'Another video', views:1236}]}]
}
Is this possible with MongoDB 3.2 and the $lookup aggregate?
 
    