(Taken from Homework 1 of CMU DB Course)
Questions:
- List all category names ordered alphabetically.
- Get all unique
ShipNamesfrom theordertable that contain a hyphen (-). - Indicate if an order's
ShipCountryis in North America (USA, Mexico or Canada) - For each
Shipper, find the percentage of orders which are late. - Get the number of products, average unit price (rounded to 2 decimal places), minimum unit price, maximum unit price, and total units on order for categories containing greater than 10 products. Order by Category ID.
- For each of the 8 discontinued products in the database, which customer made the first ever order for the product? Output the customer's
company_nameandcontact_name. - For the first 10 orders by
customer_id BLONP: get the order'sid, date, previous date, and difference between the rpevious and current. Return results ordered byorder_date(ascending). - For each
customer, get thecompany_name,customer_id, and "total expenditures". Output the bottom quartile of Customers, as measured by total expenditures. - Find the youngest employee serving each
region. If a region is not served by an employee, ignore it. - Concatenate the
product_names ordered by the Company'Queen Cozinha'on2014-12-25. Order the products byid(ascending). Print a single string containing all the dup names separated by commas likeMishi Kobe Niku, NuNuCa Nuß-Nougat-Creme....