title: Symfony2 / Doctrine : findBy with OneToMany cardinality
body: <p>I would like to if it possible (and how) to use a OneToMany relationship cardinality as findBy filter.</p>
  
  <p>For instance here, let's say I have two entities <code>User</code> and <code>Post</code> with a OneToMany relationship between them so that an user has a collection of posts.</p>
  
  <p>I am looking for a way to get all users that have at least one post, that is to say :<br>
  <code>|user.posts| &gt;= 1</code>
  or more programmatically <code>count(user-&gt;getPosts()) &gt;= 1</code></p>
  
  <p>I know this can be achieved with a QueryBuilder or DQL but I am quite sure there is a trick that allows to make it work with <code>findBy</code>.</p>
  
  <p>Here is the idea of what I am willing to do :</p>
  
  <pre><code>class UserRepository extends EntityRepository
  {
      public function myQuery()
      {
          return $this-&gt;findBy(
              array(... 'posts' ...), // What should I put here ?
              array('email' =&gt; 'ASC')
          );
      }
  }
  </code></pre>