title: Convert INT to FLOAT in SQL
body: <p>I have this Query :</p>
  
  <pre><code>   SELECT sl.sms_prefix, sum( sl.parts ) , cp.country_name, CAST(SUM(sl.parts) AS NUMERIC(10,4)) * CAST(cp.price AS NUMERIC(10,4))
  FROM sms_log sl, sms_transaction st, country_prefix cp
  WHERE st.customer_id =1
  AND st.sendtime &gt;=1329865200
  AND st.sendtime &lt;=1330037999
  AND st.sms_trans_id = sl.trans_id
  AND sl.sms_prefix = cp.prefix
  AND st.customer_id = cp.customer_id
  GROUP BY sl.sms_prefix
  LIMIT 0 , 30
  </code></pre>
  
  <p>Result:</p>
  
  <pre><code>sms_prefix  sum( sl.parts )     country_name    price   total
  ==================================================================================
  45            2                        Denmark   0.01   0.019999999552965
  63            3                        Philippines   2  6
  </code></pre>
  
  <p>As you see the <code>"total"</code> is not correct for <code>Denmark</code> because <code>sum( sl.parts )=2</code> Multiply with <code>0.01</code> the total should be <code>0.02</code>.</p>
  
  <p>Price field is <code>FLOAT</code> how I can CAST the total to float ?</p>
  
  <p>Regards,</p>