A meeting occupies [start_ts, end_ts): a meeting that ends exactly when another starts does NOT overlap with it. For each org find the maximum number of meetings running at the same moment and the earliest time that maximum is reached. Return org_id, max_concurrent and peak_start. Order by org_id.
| Column | Type |
|---|---|
| meeting_id | INTEGER |
| org_id | TEXT |
| start_ts | TIMESTAMP |
| end_ts | TIMESTAMP |
| meeting_id | org_id | start_ts | end_ts |
|---|---|---|---|
| 1 | A | 2026-08-03 09:00:00 | 2026-08-03 10:00:00 |
| 2 | A | 2026-08-03 09:30:00 | 2026-08-03 10:30:00 |
| 3 | A | 2026-08-03 09:45:00 | 2026-08-03 11:00:00 |
| 4 | A | 2026-08-03 10:00:00 | 2026-08-03 10:15:00 |
| 5 | B | 2026-08-03 13:00:00 | 2026-08-03 14:00:00 |
| 6 | B | 2026-08-03 14:00:00 | 2026-08-03 15:00:00 |
| org_id | max_concurrent | peak_start |
|---|---|---|
| A | 3 | 2026-08-03 09:45:00 |
| B | 1 | 2026-08-03 13:00:00 |
Solve it in the live editor on this page — run on sample data, then submit against hidden tests.
‹ Customers With Rising Monthly Spend · Clicks per Domain From Raw URLs ›
{{ totalCount }} questions in the style asked at Amazon, Microsoft, Google, Meta, Flipkart and more — {{ hardPct }}% Hard. Write SQL in a real database engine in your browser, run it on sample data, then evaluate against hidden tests.
Company tags show where this type of question is commonly reported in interviews. Questions, data and solutions are written by TechTown.
{{ cur.statement }}
No submissions yet. Press Evaluate to submit your query.
{{ solutionSql }}
{{ out.error }}
You have solved your 3 free questions — nice work! Log in (free) to unlock all 150 questions, keep your streak and appear on the leaderboard.