title: mongodb - perform batch query
body: <p>I need query data from collection a first, then according to those data, query from collection b. Such as:</p>
  
  <pre><code>For each id queried from a
      query data from b where "_id" == id
  </code></pre>
  
  <p>In SQL, this can be done by join table a &amp; b in a single select. But in mongodb, it needs do multi query, it seems inefficient, doesn't it? Or it can be done by just 2 queries?(one for a, another for b, rather than 1 plus n) I know NoSQL doesn't support join, but is there a way to batch execute queries in for loop into a single query?</p>