Rol: Data/BI Analyst · Herramientas: PostgreSQL (CTEs, funciones ventana, percentiles, cohortes)
Analítica operativa de tickets (SLA, tiempos de resolución y satisfacción) para priorizar mejoras y ruteo por canal.
La operación de soporte necesita entender SLA, tiempos de resolución y satisfacción (CSAT/NPS) para:
- Detectar cuellos de botella (por prioridad/canal).
- Optimizar ruteo de tickets críticos.
- Priorizar equipos/sucursales con mayor impacto.
Sintético (~3.2k tickets, 2024–2025). Tres tablas:
tickets
ticket_id, created_at, resolved_at, status, priority, category, channel, sla_target_hours, customer_id, agent_id, branch_codesurveys
ticket_id, csat_score (1–5), nps (-100..100), commentagents
agent_id, agent_name, team, seniority, branch_code
El script crea también la vista
v_tickets_enrichedconresolution_hoursy flagsla_met.
- Crear DB y conectarse:
createdb soporte_demo "C:\Program Files\PostgreSQL\18\bin\psql.exe" -U postgres -h localhost -d soporte_demo
SLA por prioridad (resueltos)
- Low: 99.4%
- Medium: 97.8%
- High: 94.7%
- Urgent: 63.6%
Tiempos de resolución por Canal × Prioridad
(horas; promedio, p50, p90)
| Canal | Prioridad | Avg | p50 | p90 |
|---|---|---|---|---|
| App | High | 8.53 | 7.88 | 14.24 |
| App | Low | 24.66 | 20.56 | 33.59 |
| App | Medium | 16.60 | 15.25 | 26.91 |
| App | Urgent | 7.07 | 7.07 | 8.04 |
| Chat | High | 10.86 | 8.73 | 21.35 |
| Chat | Low | 21.89 | 19.20 | 38.98 |
| Chat | Medium | 15.73 | 12.77 | 30.26 |
| Chat | Urgent | 7.87 | 6.51 | 12.99 |
| High | 10.36 | 8.77 | 18.37 | |
| Low | 21.88 | 18.54 | 38.38 | |
| Medium | 16.01 | 13.37 | 28.43 | |
| Urgent | 7.51 | 6.70 | 12.31 | |
| Phone | High | 10.46 | 8.13 | 21.16 |
| Phone | Low | 21.68 | 17.66 | 39.89 |
| Phone | Medium | 15.78 | 13.88 | 29.11 |
| Phone | Urgent | 6.83 | 5.40 | 11.47 |
Insights
- Urgent: mejor performance en Phone (p50 ≈ 5.4h).
- High: gana App (p50 ≈ 7.9h).
- Medium: destaca Chat (p50 ≈ 12.8h).
- Low: más eficiente Phone (p50 ≈ 17.7h).
- Gran gap de SLA en Urgent (≈ 63.6%): oportunidad de ruteo por canal + priorización inicial para subir SLA.