title: SQL: How to select year and month when customer's turnover was the biggest?
body: <p>I need to List top 10 customers by average monthly transactions amount turnover, in
  additional column indicating the year and month with highest monthly turnover of the customer.</p>
  
  <p>I made the first part - list top 10 customers by average monthly transactions amount turnover. </p>
  
  <pre class="lang-sql prettyprint-override"><code>Select column1, AVG(Case when when column1="x" then column2
                        when column1="y" then column2
                        when column1="z" then column2
                        when column1="q" then column2 End)/12 [AVG]
  from table1
  Group by column1
  Order by AVG DESC;
  </code></pre>
  
  <p>How to make the second part of the task - in
  additional column indicating the year and month with highest monthly turnover of the customer?</p>