title: Sum rows together with the same ID but different event logs with conditions
body: <p>A table has 3 different fields, the first being <code>user_id</code>, <code>event_log</code>, <code>uploaded_files</code>. </p>
  
  <pre><code>user_id       event_log       uploaded_files
  --------------------------------------------
  1             0001            1
  1             0002            1
  1             0003            1
  2             0004            5
  2             0005            2
  2             0006            1
  3             0007            1
  3             0008            4
  </code></pre>
  
  <p>I am aiming to merge the user_id rows together in one and sum up the uploaded_files column, while implementing conditions such as <code>total files &gt; 1 and &lt;6</code>. Ideally I would like this:</p>
  
  <pre><code>user_id       total_files
  --------------------------
  1             3
  3             5
  </code></pre>
  
  <p>So far I have only been able to get to:</p>
  
  <pre><code>user_id       total_files
  --------------------------
  1             3
  2             8
  3             5
  </code></pre>
  
  <p>I have gotten there by using:</p>
  
  <pre><code>SELECT user_id, sum(files_uploaded) total_files
  FROM my_table
  GROUP BY user_id
  ORDER BY user_id;
  </code></pre>
  
  <p>I've tried to add conditions: <code>ORDER BY user_id WHERE total_files &gt;1 AND total_files &lt;6</code>, but I am unable to. Is there something that I am missing? </p>