CBSE Class 12 Computer Science
Question 88 of 91
Grouping Records, Joins in SQL — Question 23
Back to all questionsSELECT c.customer_id, c.state, SUM(o.amount) AS total_order_amount
FROM Customers c, orders o
WHERE c.customer_id = o.customer_id
GROUP BY c.customer_id, c.state;