title: Max 3 values of every group
body: <p>I sorted my data to something like this and now I want to get top 3 max person_occurence by every company but I couldn't figure out how to do it.</p>
  
  <pre><code>   person_occurence company    person_id
      67               company_1  110
      66               company_2  176
      64               company_3  100
      64               company_3  196
      63               company_4  127
      62               company_1  150
      61               company_5  120
      60               company_3  140
      59               company_5  154
      59               company_5  162
      59               company_4  194
      58               company_4  109
      58               company_3  128
      58               company_1  156
  </code></pre>
  
  <p>I used this query to get max of every company but can't get top 3 max person_occurence</p>
  
  <pre><code>SELECT max(agent_occurence), company FROM table GROUP BY company;
  </code></pre>