title: Sql query returning int instead of decimals
body: <p>Working on a sql query, but found out that Sum does not like decimals, thats why decimals values (XX,XX) becomes integer. My database is build up with routines connected with measure_routine as pivot table and measurement.</p>
  
  <p>SQL:</p>
  
  <pre><code>SELECT routines.date, routines.time, SUM( IF( measurements.title =  'T_Badende_per_Time', routines.value, 0 ) ) AS T_Badende_per_Time,
                                       SUM(IF(measurements.title = 'T_Temperatur', routines.value, 0)) AS T_Temperatur
  FROM routines
  INNER JOIN measure_routine ON routines.id = measure_routine.routine_id
  INNER JOIN measurements ON measure_routine.measure_id = measurements.id
  GROUP BY routines.date, routines.time
  ORDER BY routines.date, routines.time;
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/Dtt0b.png" alt="enter image description here"></p>
  
  <p>Database:</p>
  
  <p><img src="https://i.stack.imgur.com/03WMd.png" alt="enter image description here"></p>