Dense Rank of Order Totals

easy
Unit 6 · Window Functions I0/3 to milestone

Return each order's id, total and price_rank: its DENSE_RANK by total, highest first, so equal totals share a rank and no ranks are skipped. Sort by price_rank, then id.

Schema

customers(id, name, country, signup_date)
orders(id, customer_id, order_date, total)
#window-functions#ranking2 visible + 1 hidden tests
query.sql · SQLite
Loading editor…
Run your code to see results. ⌘↵ to run · ⌘⇧↵ to submit
Dense Rank of Order Totals · TechGradify