title: QueryDsl - subquery in collection expression
body: <p>I'm using spring-data-jpa and querydsl (3.2.3)<br>
   I have a scenario where I'm creating set of predicates based on user filer/input. All of these comes to <code>BooleanExpression</code>.  </p>
  
  <p>My simplified model looks as following:  </p>
  
  <pre><code>@Entity
  public class Invoice {
      @ManyToOne
      private Supplier supplier;
  }
  
  @Entity
  public class Supplier {
      private String number;
  }
  
  @Entity
  public class Company {
      private String number;
      private boolean active
  }
  </code></pre>
  
  <p>Now, what I'm struggling with is this query:  </p>
  
  <pre><code>SELECT * FROM Invoice WHERE invoice.supplier.number in (SELECT number from Company where active=true)
  </code></pre>
  
  <p>So basically I need to subquery in <code>CollectionExpression</code> like format that will fetch all companies numbers and sets this into in() expression.  </p>
  
  <p>My spring-data repositories implements <code>CustomQueryDslJpaRepository</code> which in turn extends <code>JpaRepository</code> and <code>QueryDslPredicateExecutor</code>.<br>
  I hope the answer to this is straightforward, but I'm quite new to querydsl and didn't find the solutions so far.</p>