SQL Questions
SQL Questions
1. From the above table, write an SQL query to calculate the total purchase amount
of all orders. Return the total purchase amount.
2. From the above table, write an SQL query to calculate the average purchase
amount of all orders. Return average purchase amount.
3. From the above table, write an SQL query that counts the number of unique
salespeople. Return number of salespeople.
4. From the above table, write an SQL query to find the minimum purchase amount.
5. From the above table, write an SQL query to find the highest purchase amount
ordered by each customer. Return customer ID, maximum purchase amount.