title: How to create two virtual columns by different conditions from repeating row data using SQL?
body: <p>My database table has three columns: <code>[Date, Client, Value][1]</code>.</p>
  
  <p>I want a new table with only three clients in it - "Technics", "Metal Inc", "Sunny Day" and two virtual total columns - "Price" / August, and "Price" / 2017.</p>
  
  <p>What I tried so far and what I get: <a href="https://i.stack.imgur.com/ujAl7.png" rel="nofollow noreferrer">Click to see</a></p>
  
  <p>Why does the "For August" total <code>SUM</code> goes down the next row, but not in a new column?
  After all, my code says: <code>SELECT SUM(Value) AS 'For August'</code>.
  Any ideas?</p>