RienSQL
TASK #176 · Medium · Klarna

Top-10 Spenders by Total Purchase Amount

Your brief
The transactions table stores customer purchases through Klarna.

Write a query that returns customer_name (from customers.name) and total_spent — the customer's lifetime total purchase amount — for the top 10 customers. Sort by total_spent descending.
Expected columnscustomer_name total_spentKlarna
SQL editor
SQLite
Ctrl / ⌘ + ↵
Result

Write a query and run it to see the results.

Schema
customerscustomer_id, name, region
transactionstransaction_id, customer_id, merchant_name, amount, ts