title: knex.js join two subqueries (nested queries)
body: <p>I want to join two subqueries in knex.js and produce this sql result.</p>
  
  <pre><code>SELECT '*'
  FROM
      (
      SELECT
          `*`
      FROM
          `A`
      WHERE
          A.id = 1
  ) AS `t1`
  LEFT JOIN
      (
      SELECT
          *
      FROM
          `B`
      WHERE
         B.id = 2
  ) AS `t2`
  ON
      `t1`.`c` = `t2`.`d`
  </code></pre>
  
  <p>How can I do that?</p>