I realise this is likey to be an easy one, but my SQL is basic at best.
Lets say I have a table containing a list of orders, with 'item_id' being one of the columns. I need to display the 3 least (or 3 most) popular orders of item.
I know that I need to group the orders using item_id and then count them. Then I need to display the bottom (or top) 3 in decsending (or ascending) order. I'm just not entirely sure how to construct a query like that.
Any help would be appreciated. Thanks