Chapter 4 · Aggregations
55. Payment Method Breakdown
Medium20 XPE-Commerce
The finance team wants to know how revenue is distributed across payment methods. For each payment method, show the number of completed payments, the total amount, and the percentage of total revenue (rounded to 1 decimal). Sort by total amount descending.
Tables
- PKidINT
- FKorder_id→ orders.idINT
- payment_dateTEXT
- amountREAL
- methodTEXT
- statusTEXT
Need help?
Ask Sol
AI tutor — looks at your current query and nudges you, without spoiling the answer.
Solution
Try the hints first — solving it yourself is what makes it stick.