title: Mongo how to $lookup with DBRef
body: <p>I have a trouble(/(ㄒoㄒ)/~~). Suppose that collection A is<br> </p>
  
  <pre><code>{ 
      "_id" : ObjectId("582abcd85d2dfa67f44127e1"), 
      "bid" : [
          DBRef("B", ObjectId("582abcd85d2dfa67f44127e0")),
          DBRef("B", ObjectId("582abcd85d2dfa67f44127e1"))
      ]
  }
  </code></pre>
  
  <p><br>and Collection B: <br> </p>
  
  <pre><code>{ 
      "_id" : ObjectId("582abcd85d2dfa67f44127e0"),  
      "status" : NumberInt(1), 
      "seq" : NumberInt(0)
  },
  { 
      "_id" : ObjectId("582abcd85d2dfa67f44127e1"), 
      "status" : NumberInt(1), 
      "seq" : NumberInt(0)
  } 
  </code></pre>
  
  <p><br>I don't know how to $lookup the 'bid'. I tried<br> </p>
  
  <pre><code>db.A.aggregate(
      [
          {$unwind: {path: "$bid"}},
          {$lookup: {from: "B", localField: "bid", foreignField: "_id", as: "bs"}},
      ]
  ) 
  </code></pre>
  
  <p><br>and <br> </p>
  
  <pre><code>db.A.aggregate(
      [
          {$unwind: {path: "$bid"}},
          {$lookup: {from: "B", localField: "bid.$id", foreignField: "_id", as: "bs"}},
      ]
  )
  </code></pre>
  
  <p><br>but it doesn't work. Anybody can help?  Thanks.</p>