title: Symfony2 / Doctrine2 - get sql min,max date values
body: <p>My problem is when i want to get the max or the min date value between 2013-04-08,2013-04-07 and 2013-04-06, the response is always 2013-04-08 for the min and the max</p>
  
  <p>my script  : </p>
  
  <pre><code>$max_date =     $em -&gt;createQuery("SELECT MAX(p.date) FROM TrackingMarqueBundle:PointdeventeOperateursSaisie p")
                          -&gt;getSingleScalarResult();
      $min_date =     $em -&gt;createQuery("SELECT MIN(p.date) FROM TrackingMarqueBundle:PointdeventeOperateursSaisie p")
                          -&gt;getSingleScalarResult();
  </code></pre>
  
  <p>Any help please? </p>