title: Calculate SUM Column Wise using dinaymic query in SQL Server
body: <pre><code> id varname 1area 2area 3area 4area
   ------------------------------------
   1   abc      345  3.7   34     87
   1   pqr      46    67   78     55 
   1   lmn      67   99    33     44 
   2   xyz      78    78    33    32
  </code></pre>
  
  <p>I need to calculate <code>SUM</code> of column query.</p>
  
  <p>Is it possible to get column count using while loop?</p>