Write a SQL query that displays for each customer their customer code, name, tot
ID: 3546597 • Letter: W
Question
Write a SQL query that displays for each customer their customer code, name, total balance (from Customer table), their total purchases (from Invoice), and the number of individual products they purchased (if the customer's invoice is based on three products, one per LINE_NUMBER, you are counting three individual product purchases). Call this column for instance Number_of_purchases. Add to the query the average purchase amount per product made by each customer, using a subquery and a column name such as Average_purchase_amount.
Explanation / Answer
Write a SQL query that displays for each customer their customer code, name, tot
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.