Recent Users
Which users signed up in March 2024?
- Filtering
- Sorting
Challenge brief
Understand the request
Onboarding Team is analysing the March 2024 new user cohort for a welcome-sequence review.
List user_ids who signed up on or after 2024-03-01.
Return
- user_id
Constraints
- Include signups on or after 2024-03-01 and before 2024-04-01
- Order by user ID
Data you will use
Review the relevant tables before deciding how to join, filter, or aggregate them.
users
user_idINTEGERcountryTEXTsignup_dateDATE
Hints, when you need them
Open one clue at a time so you still do the reasoning.
Hint 1
All signup data is in users. Filter signup_date >= '2024-03-01' to get March users. No JOIN needed.
Hint 2
SELECT user_id FROM users WHERE signup_date >= '2024-03-01'.
Hint 3
Build question 9 from the required result grain: choose the driving table, add only the joins and filters needed for that grain, then apply aggregation and deterministic ordering.
Verified SQL answer
Attempt the problem first, then compare structure and reasoning—not just syntax.
Reveal solution and explanation
SELECT user_id FROM users WHERE signup_date >= '2024-03-01' AND signup_date < '2024-04-01' ORDER BY user_id;Why this works
Use a half-open March date range so future signups do not leak into the cohort. The exclusive April boundary remains correct for date or timestamp values.
Success check
8 users — user_ids 5 through 12, all signed up in March 2024
Expected result
Use this output to verify values, aliases, ordering, and row count.
| user_id |
|---|
| 5 |
| 6 |
| 7 |
| 8 |
| 9 |
| 10 |
| 11 |
| 12 |
Learn the concepts behind this answer
Strengthen your understanding with these targeted learning topics:
Continue practicing
Explore related company challenges
Apple
Independent Apple-style product, retail, services, support, workforce, and device-usage SQL practice.
Google
Independent Google-style search, advertising, user-engagement, and video-product SQL practice.
Amazon
Independent Amazon-style e-commerce, warehouse, inventory, and customer analytics SQL practice.
Return to the complete interview preparation experience.