Order Value Histogram

easy
Unit 2 · Aggregation I0/3 to milestone

Build a histogram of order values with buckets 50 wide: 0–49.99 goes in bucket 0, 50–99.99 in bucket 50, and so on. Return bucket_start and orders for every bucket that has orders, sorted by bucket_start.

Schema

customers(id, name, country, signup_date)
orders(id, customer_id, order_date, total)
#aggregation#bucketing1 visible + 1 hidden tests
query.sql · SQLite
Loading editor…
Run your code to see results. ⌘↵ to run · ⌘⇧↵ to submit
Order Value Histogram · TechGradify