title: Doctrine one-to-many situation: how to easily fetch related entities
body: <p>To simplify, two entities are defined: User and Comment. User can post many comments and every comment has only one user assigned, thus Comment entity has:</p>
  
  <pre><code>/**
   * @var \Frontuser
   *
   * @ORM\ManyToOne(targetEntity="Frontuser")
   * @ORM\JoinColumns({
   *   @ORM\JoinColumn(name="ownerUserID", referencedColumnName="id")
   * })
   */
  private $owneruserid;
  </code></pre>
  
  <p>However, when in action:</p>
  
  <pre><code>$orm = $this-&gt;getDoctrine()-&gt;getManager();
  $repo = $orm-&gt;getRepository('CompDBBundle:Comment');
  $repo-&gt;findBy(array('owneruserid' =&gt; $uid);
  </code></pre>
  
  <p>Error occured, that there's no such field like <code>owneruserid</code>.</p>
  
  <p>How can I fetch all the user's comments then? The same happens to similar relations in my DB - looks likes you cannot run <code>find()</code> with foreign keys as parameters. I believe a function <code>$user-&gt;getComments()</code> should be automatically generated/recognised by Doctrine to allow efficient, quick access to related entities. </p>
  
  <p>The example's simple but, what if there are more entities related to my User in the same way? Do I have to declare repositories for each and try to fetch them by it's <code>owneruserid</code> foreign keys?</p>