title: How to create a result set with the max value of each TILE and the number of itens in that TILE
body: <p>If I have a table like this</p>
  
  <pre><code>id product_name  price
  
  1   product_1     5    
  2   product_2     10 
  3   product_3     100
  4   product_4     200   
  5   product_5     9000     
  </code></pre>
  
  <p>If I execute a query like this:</p>
  
  <pre><code> select  price,  ntile(3) over(order by price) as rank from products order by price.
  </code></pre>
  
  <p>It will produce a result roughly like this: </p>
  
  <pre><code>   id  product_name   price       rank
  
      1   product_1     5             1
      2   product_2     10            1
      3   product_3     100           2
      4   product_4     200           2
      5   product_5     9000          3
  </code></pre>
  
  <p>But I would like to expand this a little more and get the max value of each tile and the number of itens on that tile.</p>
  
  <pre><code>   price    items
      10       2
      200      2
      9000     1  // I think I won't use the last tile max value, but it's here anyway.
  </code></pre>
  
  <p>I don't have the knoleged to get the result that I want so I little help is welcome.</p>