title: Arithmetic overflow error converting expression to data type int SQL Server
body: <p>I am getting the following error :</p>
  
  <blockquote>
    <p>Msg 8115, Level 16, State 2, Line 1<br>
    Arithmetic overflow error converting expression to data type int.</p>
  </blockquote>
  
  <p>The numbers are not too big for <code>bigint</code>. I am unable to point out what is going wrong here. Any pointers please.</p>
  
  <p>Query</p>
  
  <pre><code>DECLARE SP bigint
  DECLARE LP bigint
  
  SET SP = 125000000 
  SET LP = 88300000 
  
  SELECT a = CAST((AVG(LP * 100 / CAST(SP AS DECIMAL(10, 2)))) AS DECIMAL(10,2))
  </code></pre>