Suppose I have a column called "fruits" I want to select all of the top fruits, ranked by fruits (and group by + count).
Fruits:
orange
orange
apple
banana
apple
apple
In this case, the select statement would return:
apple, 3
orange, 2
banana, 1