title: SQL find name doubles and sum values
body: <p>I have one table records with the columns:</p>
  
  <pre><code>|rec.id|rec.name|user.name|hours|
  </code></pre>
  
  <p>and the values respectively:</p>
  
  <pre><code>|1     |google  |Admin    | 12  |
  |2     |yahoo   |Admin    | 1   |
  |3     |bing    |Manager  | 4   |
  </code></pre>
  
  <p>What i want to do is take all of the records with the same user.id and sum there hours together in SQL. Perhaps its the early mornign but i cant seem to figure out a way of doing this. I thought about using sql to find the duplicates but thats only going to return a number and not what i want to do with them. This sounds like a really simple thing so sorry in advance.</p>