Find Customers with High-Priced Ticket Purchases
The marketing team wants to identify customers who tend to buy premium event tickets, so they can target them with special offers.
Your task is to find all customers who have made at least one purchase where the ticket price was higher than average.
To solve this, you'll use a subquery inside the WHERE
clause to compare each purchase to the overall average ticket price.
What to Show
From the event_ticketing.sqlite
database, return:
name
(from thecustomers
table)
Only include customers who have purchased at least one ticket with a price above the average across all purchases.
Instructions
Write a SQL query that joins customers
with purchases
, and filters for rows where the ticket price is greater than the average price.
Use a subquery inside the WHERE
clause to calculate the average ticket price.
Lecture
AI Tutor
Design
Upload
Notes
Favorites
Help
Code Editor
Tables
Execution Result