title: SQL get the min/max time per date in one row
body: <p>i need a help here, im trying to build a query which returns the max and min time per date in one row for example i have this table:</p>
  
  <pre><code>+---------+------------------------+----------+
  |name     |Dates                   |Door      |
  +---------+------------------------+----------+
  |Maria    |2012-02-14 09:04:45.397 |Garage    |
  |Maria    |2012-02-14 12:14:20.997 |Entrance |
  |Maria    |2013-02-14 12:20:59.407 |Exit      |
  |Maria    |2012-02-13 12:24:20.997 |garage    |
  |Eli      |2013-02-13 10:30:59.407 |Entrance  |
  |Eli      |2013-02-13 12:30:59.407 |Exit      |
  +---------+------------------------+----------+
  </code></pre>
  
  <p>the results should be like :</p>
  
  <pre><code>+---------+------------------------+-----------------------------+
  |name     |Entrance                |Exit                         |
  +---------+------------------------+-----------------------------+
  |Maria    |2012-02-14 09:04:45.397 |2013-02-14 12:20:59.407      |
  |Maria    |2012-02-13 12:14:20.997 |          null               |
  |Eli      |2013-02-13 10:30:59.407 |2013-02-13 12:30:59.407      |
  +---------+------------------------+-----------------------------+
  </code></pre>
  
  <p>any help would appreciate :)</p>