# Two Names, One Campaign

> The ad team and the push team never agreed on naming. Find where they secretly meant the same thing.

Canonical URL: <https://datadriven.io/problems/campaign_match_rate>

Domain: SQL · Difficulty: easy · Seniority: L4

## Problem

The advertising team labels campaigns in loud uppercase (ad_impressions.ad_campaign, e.g. FLASH_SALE_48H), while the push-notification team uses lowercase slugs (push_notifs.campaign, e.g. flash_sale). The two systems were never reconciled, but some campaigns are clearly the same effort under different names: they share a theme keyword. An ad_impressions row is considered "reconciled" if its ad_campaign shares one of the theme keywords 'flash', 'loyalty', or 'summer' with at least one non-null push_notifs.campaign value (matching is case-insensitive). Return the percentage of all ad_impressions rows (out of every ad_impressions row) that are reconciled. Return a single number between 0 and 100.

## Related

- [All practice problems](https://datadriven.io/problems)
- [Mock interview mode](https://datadriven.io/interview/campaign_match_rate)
- [SQL Interview Questions](https://datadriven.io/sql-interview-questions)
- [Data Engineering Interview Prep Guide](https://datadriven.io/data-engineer-interview-prep)
- [Daily Challenge](https://datadriven.io/daily)

---

Source: DataDriven (https://datadriven.io). 100% free data engineering interview prep. Live code execution against Postgres 16, Python 3.11, and Spark sandboxes. No paywall, no premium tier, no signup gate.