<s>[INST] Write a SQL code to count the number of shops in each unique district based on their addresses.  [/INST] SELECT shop_address_district, COUNT(*) AS total_shops_per_district FROM order_transaction.transaction_detail_deprecated GROUP BY shop_address_district; </s>