Product managers at Atlassian are tracking the efficiency of the development team in squashing bugs. They need to compare the average time it takes to resolve "Critical" bugs versus "Major" bugs to ensure resources are allocated correctly.
Write an SQL query to find the average resolution time in hours for these two severity levels.
| ticket_id(INTEGER) | severity(VARCHAR) | created_at(TIMESTAMP) | resolved_at(TIMESTAMP) |
|---|---|---|---|
| 1 | Critical | 2026-02-01 08:00:00 | 2026-02-01 12:00:00 |
| 2 | Critical | 2026-02-01 10:00:00 | 2026-02-01 16:00:00 |
| 3 | Major | 2026-02-01 09:00:00 | 2026-02-02 09:00:00 |
| 4 | Major | 2026-02-02 10:00:00 | 2026-02-03 10:00:00 |
| 5 | Minor | 2026-02-01 08:00:00 | 2026-02-01 10:00:00 |
| 6 | Critical | 2026-02-03 08:00:00 | null |
| severity(VARCHAR) | average_resolution_hours(DECIMAL) |
|---|---|
| Major | 24 |
| Critical | 5 |