title: Calculate percentage in MS SQL Server with int columns
body: <p>I am trying to calculate the total amount for charity. Each row has a bid amount and a charity percentage. 
  The structure of the fields looks like this:</p>
  
  <p>CurrentBid INT
  CharityPercentage INT &lt;-- 0-100, where 100 is donating all to charity</p>
  
  <p>So i tried this:</p>
  
  <pre><code>SELECT CurrentBid, CharityPercentage, CurrentBid * (CharityPercentage / 100) AS TotalCharity FROM Items
  </code></pre>
  
  <p>However it yields this:</p>
  
  <pre><code>50  100 50
  70  100 70
  25  50  0
  50  25  0
  30  10  0
  55  15  0
  </code></pre>
  
  <p>It works as long as the percentage is 100. Anything below and its 0. My guess is that it has to do with the int column.</p>
  
  <p>Any ideas on how to solve it? I have also tried to convert the int using a CAST in the select statement but that did not work. Its a very big procedure to change the INT column to something else.</p>