Write a SQL query to analyze operational performance by team, joining service data with staffing data and aggregating SLA attainment by month at Hewlett Packard Enterprise. Use the provided service and staffing tables. Include months represented by service records, even when staffing data is unavailable.
team_name, month_start, total_requests, sla_met_requests, sla_attainment_pct, and staffed_agentsmonth_start, then team_name| Column | Type | Description |
|---|---|---|
| service_idPK | INT | Unique service record identifier |
| team_name | VARCHAR(100) | Operations team responsible for the service record |
| service_type | VARCHAR(100) | Type of service request |
| resolved_at | TIMESTAMP | Timestamp when the service request was resolved |
| sla_met | BOOLEAN | Whether the service request met its SLA |
| Column | Type | Description |
|---|---|---|
| staffing_idPK | INT | Unique staffing record identifier |
| team_name | VARCHAR(100) | Operations team being staffed |
| month_start | DATE | First day of the staffing month |
| staffed_agents | INT | Number of staffed agents during the month |