title: execution modulo on a large number in t-sql
body: <p>I need to calculate the remainder of one number divided by another. for instance with these numbers:</p>
  
  <p>271011240311350356232122 % 97 </p>
  
  <p>When I just want to do that in a sql statement, it works like a charm: </p>
  
  <p>select 271011240311350356232122 % 97;</p>
  
  <p>But when I have that large number in a varchar variable, I can't seem to get the job done.
  I can't convert it into a int or even bigint, because it's too large. I can't convert it into a real because you can't use the modulo operator on a real number.</p>
  
  <p>Any ideas...?</p>