Sub topic 11
Monitoring queues and escalated cases
This chapter assumes you can create queues and escalation rules, and that you can read basic SOQL. It shows how to check that cases are being picked up from queues and that escalations fire as designed.
What to watch
Routing and escalation can fail without anyone noticing. A queue can fill with cases nobody owns, and an escalation rule can stop matching after a field change. Two signals cover most problems:
- Queue backlog: open cases still owned by a queue, and how long they have waited.
- Escalated cases: open cases where the Escalated flag (
IsEscalated) is set.
List views for queues
The fastest check is a case list view. In the Cases tab, create a view filtered by Owner equal to the queue name, with Closed equal to false. Sort by Date/Time Opened, oldest first. Agents use the same view to claim work, so one view serves both monitoring and daily operation.
In the Service Console, queues also appear in the list view picker. Supervisors can pin a view for each queue they manage.
Querying with SOQL
SOQL is useful for quick checks in Developer Console or in a scheduled job. This query lists open cases that are escalated, oldest first:
SELECT Id, CaseNumber, Subject, Priority, Owner.Name, CreatedDate
FROM Case
WHERE IsEscalated = true AND IsClosed = false
ORDER BY CreatedDate ASCThe IsClosed = false filter keeps old closed cases out of the result. Without it, the list grows forever.
This query lists open cases that are still waiting in a queue:
SELECT Id, CaseNumber, Subject, Status
FROM Case
WHERE Owner.Type = 'Queue' AND IsClosed = false
ORDER BY CreatedDate ASCOwner is a polymorphic relationship, so Owner.Type tells you whether the owner is a User or a Queue. If the first rows are days old, either the queue has no active members or agents are not watching it.
Reports and dashboards
Reports let you track trends instead of a single moment. Build them like this:
- Create a report with the Cases report type.
- Filter on Closed equal to false.
- Group by Case Owner. Queue names appear as owners, so backlog per queue shows up as group counts.
- Add the Escalated field as a second grouping or as a filter set to true.
- Add the Age (Hours) or Age (Days) summary field to see how long cases have been open.
Put the report on a dashboard as a table or bar chart. You can also subscribe supervisors to the report so it arrives by email on a schedule.
Reading the results
| What you see | Likely cause |
|---|---|
| Old cases in a queue, none escalated | No escalation rule entry matches, or business hours stop the age clock |
| Many escalated cases, all with the same owner | The escalation action reassigns to one user or queue that is overloaded |
| No cases in a queue that should get them | The assignment rule entry sends them elsewhere, or the rule is inactive |
| Escalated cases that are already closed | The report is missing a closed filter |
Exercise
A supervisor wants a list of open cases that have not yet been picked up by any agent. Which SOQL conditions identify them, and why is the closed filter needed?
Show answer
Use WHERE Owner.Type = 'Queue' AND IsClosed = false. Owner.Type = 'Queue' means no individual user owns the case yet. IsClosed = false removes finished cases, which could otherwise still show a queue as the last owner.