IT CanvassTalk to an advisor
ServiceNow Troubleshooting · LessonBy , ServiceNow Trainer, 9 yrs · Published · current release · fixes

Fixing slow queries

Diagnose and speed up slow lists and scripts.

Quick answer

Slowness usually traces back to the query. Check these.

Slowness usually traces back to the query. Check these.

  • Review the Slow Query log for the offending statement.
  • Ensure filtered fields are indexed.
  • Avoid expensive dot-walking and calculated fields in list views.
  • Replace record loops that count with GlideAggregate.
  • Add setLimit() and paginate large operations.

Quick check

+0 XPStreak ×0
Question 1 of 2
What speeds up filtering on a field?

Frequently asked questions

What does the term Fixing slow queries refer to in ServiceNow?
Slowness usually traces back to the query. Check these.
What is another point to note about Fixing slow queries?
Review the Slow Query log for the offending statement. Ensure filtered fields are indexed. Avoid expensive dot-walking and calculated fields in list views.
Practise this on your own free instance.
Set up your free instance →
Already working on ServiceNow and stuck on a live ticket?Get an expert ServiceNow developer on screen-share to finish your daily tasks with you. Deliver on time, protect your reputation and your job. Monthly support only, no task-wise plans.Task assigned · no idea where to startStill stuck · your job on the lineExpert joins your screenDelivered on timeExplore On Job Support