Skip to content
SQL for Data Analysis: Answer Business Questions with PostgreSQL
Text· 7 minMembers-only lesson

Ranking and the top N per group

Ranking questions are everywhere: the best-selling product, the three biggest customers of each country, the latest order of each customer. In Module 4 you answered the first with ORDER BY ... LIMIT 1. The moment the question says "per group",…

This lesson is for members only

This lesson belongs to the full course

Buy the course once, keep access with no time limit.

Lessons marked "open access" work without an account.

We measure site traffic (GA4, Mixpanel). If you say yes, Microsoft Clarity also records how the public pages are used (clicks, scrolling) and we tune Meta ads. Nothing is stored on your device before you answer, and your choice sticks for 6 months.