CREATE TABLE device (Device_ID INT, Device TEXT, Carrier TEXT, Package_Version TEXT, Applications TEXT, Software_Platform TEXT)
CREATE TABLE stock (Shop_ID INT, Device_ID INT, Quantity INT)
CREATE TABLE shop (Shop_ID INT, Shop_Name TEXT, Location TEXT, Open_Date TEXT, Open_Year INT)

Give a bar chart showing how many shops in each carrier, list by the the number of carrier in desc.
SELECT Carrier, COUNT(Carrier) FROM stock AS T1 JOIN device AS T2 ON T1.Device_ID = T2.Device_ID JOIN shop AS T3 ON T1.Shop_ID = T3.Shop_ID GROUP BY Carrier ORDER BY COUNT(Carrier) DESC
SELECT "Carrier", COUNT("Carrier") FROM "stock" AS "T1" JOIN "device" AS "T2" ON "T1"."Device_ID" = "T2"."Device_ID" JOIN "shop" AS "T3" ON "T1"."Shop_ID" = "T3"."Shop_ID" GROUP BY "Carrier" ORDER BY COUNT("Carrier") DESC NULLS LAST