SQL Challenges · WEEKLY QUACK CHALLENGE!
PONDIFY WRAPPED
Difficulty: hard
Producer Pochard squints at the year-end streaming report. The numbers dont lie, Duckbert — one artist showed up in every single ducks top five this year. But heres the twist: not one duck crowned them #1. Theyre the shadow hit of the pond. Find the secret artist.
Your task
For each duck, rank artists by play count. The secret hit is the one artist who sits in every duck’s top 5 yet is no duck’s number one. Return that artist’s name. You will be working with the `plays`, `tracks`, and `artists` tables.
Tables
plays (815 rows)
| column | type |
|---|---|
duck_id | INTEGER |
track_id | INTEGER |
played_at | TIMESTAMP |
tracks (16 rows)
| column | type |
|---|---|
track_id | INTEGER |
title | VARCHAR |
artist_id | INTEGER |
artists (8 rows)
| column | type |
|---|---|
artist_id | INTEGER |
name | VARCHAR |
genre | VARCHAR |
Database: https://dbquacks.com/data/databases/weekly_202636_10_pondify.duckdb
This page as markdown: https://dbquacks.com/challenges/weekly/10.md