Does anybody know how to display bar charts according to the number of bars you want to see?
For instance, using the sample dataset, I would like to view the top 3 categories based on the highest total ratings. Currently my code is:
select category, sum(rating) as "Total rating" from PRODUCTS group by category, vendor order by sum(rating) desc limit 3
However, it only shows this results which is not what I want.
What I would like to display are the 3 bars of categories: Gizmo, Gadget, and Widget
Does anybody know how I can do this?