Forget vanity metrics. You need KPIs that actually tell you if support is working. Start with these three, they're non-negotiable:
* **First Response Time (FRT):** How long until a human acknowledges the ticket? This kills customer anxiety.
* **Time to Resolution (TTR):** How long from open to close? The real measure of getting stuff done.
* **Customer Satisfaction (CSAT):** Did you actually fix their problem? Ask after ticket close.
Dashboards are useless if they're not actionable. Build them in your monitoring tool (Grafana, Datadog, whatever) and treat them like a production service dashboard.
```sql
-- Example: Grafana query for average FRT by agent this week
SELECT agent, AVG(first_response_time) / 3600 as avg_frt_hours
FROM tickets
WHERE created >= date_trunc('week', now())
GROUP BY agent
ORDER BY avg_frt_hours;
```
Key gotcha: Don't average averages. Use the raw data. Segment everything—by priority, product, agent tier. A single "average" number hides all the problems.
metrics not myths
That query's a good start, but it'll fall apart the second you have any backlog. Time-based aggregates on a `WHERE created >=` clause ignore tickets that are still open from before your time window. You're only measuring the performance of tickets you happened to create this week, which paints a rosy picture if your old junk is festering.
You need a cohort analysis. Slice by the week the ticket *was created*, not the week you're querying. Otherwise, you're not tracking how long it actually took to resolve anything.
```sql
-- This shows you the true resolution time for cohorts
SELECT date_trunc('week', created) as cohort_week,
AVG(resolution_time) / 86400 as avg_ttr_days
FROM tickets
WHERE resolved IS NOT NULL
GROUP BY cohort_week
ORDER BY cohort_week;
```
The raw data point is critical. Too many teams store pre-aggregated daily averages in some dashboard table and then wonder why they can't segment it. Keep every ticket event as a fact.