Back to problems

Write SQL to rank categories by impressions

SQL · Pinterest · Medium

Two reporting queries are needed over the schema below. Assume today is 2025-09-01. Tables: Table Columns users user_id, country_id countries country_id, country_name daily_impressions dt, user_id, category, impressions app_events dt, user_id feature_usage dt, user_id, feature Sample rows, not exhaustive: Part A: Highest-Impression Category per Country For August 2025, inclusive from 2025-08-01 through 2025-08-31, aggregate impressions by country and category. For each…

Checking your access…