title: mysql sum question
body: <p>Is it possible to get the sum of a column and all the column itself using one query?
  I mean, I need SUM(Result.num) and the individual Result.num as well, but I dont want to use two separate queries for the purpose? the idea result might be the SUM as another column in the result.
  Result might look like:
  col1
  Result.num1, SUM
  Result.num2, SUM
  Result.num3, SUM
  ....</p>
  
  <pre><code> SELECT SUM(Result.num) 
     FROM (SELECT COUNT(colA) AS num 
             FROM Table1 
         GROUP BY colB) AS Result;
  
   SELECT Result.num 
     FROM (SELECT COUNT(colA) AS num 
             FROM Table1 
         GROUP BY colB) AS Result;
  </code></pre>