Stripe's growth team wants to count customers who became paying customers in March 2025. A customer counts only if their earliest successful charge (status = 'succeeded') happened between 2025-03-01 and 2025-03-31 inclusive. Customers who already had a successful charge before March, or whose first success came in April or later, do not count. Failed charges never count as a first charge. Write an SQL query that returns customer_id and first_success_date (the date of that first successful charge). Order the results by customer_id ascending.
Loading…
Try solving the question with the schema explorer and hints first. When ready, reveal the verified canonical query and step-by-step logic breakdown.
Ask questions, share alternate queries, and explore solutions
Your recent query executions and answer checks
This will insert the verified MySQL solution into your editor so you can study how each clause transforms the table.