Tags / greatest-n-per-group
Using Window Functions in MySQL: Fetching Last N Rows for Multiple Users
Retrieving the Latest Records from a Table Using Row Numbers in SQL
SELECT DISTINCT ON (user_id, activity_type_id, EXTRACT(year FROM start_date_local))
Querying Single Rows in a Table with Multiple Rows in a Subquery Using Row Number and Aggregate Functions
Retrieving Last Updated Rows in MySQL: A Comparative Analysis of Different Approaches
Optimizing Queries on Nested JSON Arrays in PostgreSQL: Advanced Techniques for Filtering and Selecting Specific Rows
How to Fix SQL Distinct with ORDER BY: Avoiding Duplicates and Getting the Right Results