Your question is Top N SQL Query. Start with the requirements and the one table on the right.
Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.
Write a SQL query to get the 3rd largest number.
Use the number_values table and treat duplicate values as one value. Ignore NULL values. Return no row when fewer than three distinct non-null numbers exist.
third_largest_number.| Column | Type | Description |
|---|---|---|
| idPK | INT | Unique identifier for the stored number |
| number_value | NUMERIC | Number considered for ranking |