Question: SELECT customer.name, SUM ( payment . payment _ amount ) FROM customer JOIN payment ON customer.customer _ id = payment.customer _ id GROUP BY customer.name
SELECT customer.name, SUMpaymentpaymentamount FROM customer
JOIN payment ON customer.customerid payment.customerid
GROUP BY customer.name
WHERE payment.paymentamount
Why would this query not work as expected?
The WHERE clause should come before the GROUP BY clause
The SUM function function won't work with the paymentamount column
The JOIN operation is performed incorrectly
The GROUP BY clause should come before the JOIN operation
The query is missing an ORDER BY clause
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
