ClusterEyeClusterEye
Request DemoStart free trial
Performance

A slowing SQL Server query: finding a plan change and comparing plans

In MSSQL Performance Analytics use the Performance tab for the overall state of the instance, the Plan Changed mode of the Queries tab to find the query that changed plan, read Plan Insights in the drawer, compare the old and new plan with Compare Plans and, if needed, consider Query Store plan forcing.

Scope

Engines
SQL Server
Roles
AdminDBAViewer
ClusterEye
ClusterEye 1.6.50 and laterWritten from the product code
Prerequisites
  • Plan comparison and plan forcing need Query Store. When Query Store is off the Compare Plans window shows a warning, the Plan Forcing panel says 'Query Store is OFF on this database — enable it (READ_WRITE) to force plans.' and the Force button is disabled; with it off plans may come from the plan cache, and cache entries are evicted under memory pressure (enable Query Store for durable history).
  • Reading the page is open to all monitoring roles (Admin, DBA, Viewer). The 'Force' and 'Unforce' buttons in the Plan Forcing panel are visible to a Viewer too, but the server accepts the action only for Admin or DBA. 'Capture plan' in the drawer needs the Query permission (Admin/DBA); 'AI Query Assist' needs an Enterprise licence.
  • With the active-session sampler off the Load columns and tile stay empty ('Load is empty: the active-session sampler is off'); it is turned on under Settings → Agent Runtime Config (Admin).

When this guide helps

  • sql server query suddenly got slow
  • sql server query plan changed
  • how to find a plan regression in sql server
  • sql server compare execution plans old plan new plan
  • sql server query store force plan
  • sql server parameter sniffing slow query
  • sql server query slower than yesterday

Steps

  1. Step 1: Observe → Performance Analyzer → MSSQL → Performance

    Do

    On the MSSQL Performance Analytics page pick the node and open the Performance tab (the heading is 'Performance'); choose the time range at the top right. Look at the tiles at the top first, then the 'Wait analysis' and 'Top resource consumers' cards.

    Look for

    Tiles: Batch requests, Compilations, CPU & scheduler, Page life expectancy, Memory grants, I/O latency (or Page reads), Concurrency. In 'Wait analysis' a 'By category over time' / 'Top waits' switch; in the 'Top waits' table Wait, Category, ms/s, Avg wait, Signal % and Status. In the 'Top resource consumers' table Statement, Database, DB time, Avg, Execs, Reads and Type.

    How to read it

    This tab helps you tell whether the problem comes from one query or from the instance as a whole. The Compilations tile shows compilations as a share of batch requests and recompilations as a share of compilations; per the tile's tip a recompilation share under 10% is healthy. Page life expectancy is judged against a pool-scaled floor (300 s per 4 GB of buffer pool); the Memory grants tile shows RESOURCE_SEMAPHORE wait time and queued grants. Clicking the 'Concurrency' tile opens the Deadlocks & Blocking tab. Clicking a category in Wait analysis opens Deadlocks & Blocking (its Blocking tab) for a category starting with 'lock' and the Queries tab for the others. Clicking a 'Top resource consumers' row opens that statement in the Queries tab; the table is ranked by total elapsed time in the window. If one statement stands out and the instance as a whole is calm, go to the next step.

  2. Step 2: Observe → Performance Analyzer → MSSQL → Queries

    Do

    Open the Queries tab (the heading is 'Query Intelligence'). Click the 'Plan Instability' tile at the top or pick the 'Plan Changed' mode in the 'All Queries' card; the 'Regressed' mode lists queries that slowed down. If needed tick 'Plan Changed' in the 'Problems' chips and sort by the 'Δ vs 7d' column.

    Look for

    Tiles: Load, Running now, Blocking, Resource Pressure, Problem Queries, Regressions, Plan Instability ('queries changed plan · 24h'). A 'Plan Regression Campaigns' card where present. On the rows a gold 'plan N' tag under the query text and the 'Plan Instability', 'Plan Regression', 'Plan Risk' and 'Regression' badges; the 'Δ vs 7d' column.

    How to read it

    The 'Plan Changed' mode shows queries whose plan changed in the last 24 hours (the plan hash differed) or that carry a 'Plan Instability' or 'Plan Regression' badge; the tip of the 'plan N' tag on a row reads 'N plan change(s) in 24h'. The badge tips are in the code: 'Plan Regression' says the plan changed and the mean duration rose right after, so the new plan is likely worse, and tells you to compare plans before forcing one; 'Plan Instability' says the plan hash changed at least 3 times in the last 24 hours (parameter sensitivity?); 'Plan Risk' says the mean jumped without a matching call-rate change, which points to plan drift. The 'Plan Regression Campaigns' card groups events where several queries changed plan in a tight window and its tip calls that 'a likely shared cause'; in that case, instead of digging into the queries one by one, think about what happened at that time (a statistics update or a cache flush, for example; that is DBA interpretation, the screen does not name the cause). Δ vs 7d is the change of the mean duration against the 7-day baseline. These signals rest on plan hashes from Query Store; if the plan did not change but the query is slow, see step 5.

  3. Step 3: Observe → Performance Analyzer → MSSQL → Queries

    Do

    Click the suspect row; the drawer titled 'Impact N · health N' opens. Read the 'Query', 'Markers', 'Execution plan' and 'Plan Insights' sections.

    Look for

    In the title a bottleneck tag (for example 'CPU · 80%'; its tip holds the evidence sentence). Under 'Query' the hash, plan_handle, executions, avg dur, avg cpu, avg reads and total dur. In the 'Execution plan' section the plan view and, where it applies, the warning 'Plan changed since capture: the query now runs under a newer plan than the one shown.' In 'Plan Insights' 'Plan changed N time(s) in the last 24h', 'Latest change: time — old hash → new hash', an 'avg X → Y' tag, the access change per table (a 'seek lost' tag), 'missing index' / 'new warning' tags and an 'N other queries still use ...' line.

    How to read it

    The Plan Insights section appears only when the plan-change count over the last 24 hours is above zero or Query Store history holds a real change marker. This section reads only stored telemetry and captured plans (a missing plan may be read once through the agent's read-only plan lookup). The 'avg X → Y' tag compares each plan's mean duration as SQL Server reports it; a difference within ±10% counts as 'no change'. The screen also writes the reading: when a slowdown and a plan change appear together it says to check for data growth or blocking; when the duration did not move it says the change needs no action on its own; when it got faster it says the query got faster after the change. 'seek lost' means a table is no longer read with a seek. The 'N other queries still use <index>' line says other queries still depend on the index the new plan stopped using (with their CPU share), so changing that index affects them too. When a plan was not captured the screen says '... not captured, so what changed inside the plan cannot be shown.' and gives the reason beside each hash; that does not mean the plan did not change. The 'Capture plan' button of the Execution plan section needs the Query permission; a Viewer reads the stored plan and cannot see parameter values ('Parameter values hidden — requires Query permission.').

  4. Step 4: Observe → Performance Analyzer → MSSQL → Queries

    Do

    Click the 'Compare Plans' button beside the Plan Insights heading (it appears when the latest change has both an old and a new hash and the database is known). In the 'Compare Execution Plans' window read, in order, Runtime Stats, the difference summary, Plan Forcing and the two plans.

    Look for

    A warning at the top of the window when Query Store is off. The 'Runtime Stats (last 24h)' table: Executions (24h), Avg Duration, Avg CPU and Avg Reads, each with Plan A (previous), Plan B (current) and Δ; an 'Active window' row. In the difference summary 'Added operators', 'Removed operators', 'row estimate ±%', 'new missing-index hint' and 'new warnings'. The 'Plan Forcing' card ('approval-gated'): Plan, Avg duration, Avg reads, Executions and Action, with 'recommended', 'current' and 'forced' tags. At the bottom the 'Plan A (previous)' and 'Plan B (current)' plans, each with a 'plan cache' or 'query store' tag.

    How to read it

    Runtime Stats shows how each plan actually performed while it was active over the last 24 hours; for duration, CPU and reads a higher value is worse (the tip says so) and a percentage difference is printed only when it exceeds 5%. If the new plan (B) is clearly worse in duration and reads there is a plan regression; if the numbers are close, the plan difference does not explain the performance and the search should move elsewhere (data, waits, parameters). The tag on each plan pane gives its source: 'query store' is durable history; 'plan cache' comes from sys.dm_exec_query_plan and cache entries are evicted under memory pressure. Plan Forcing lists the Query Store plans with average duration, reads and execution count. The 'recommended' plan is the one with the lowest average duration among plans that ran, and the API recommends 'Force plan N' only when the current (most recently executed) plan is at least 1.5 times slower than it; otherwise it says 'no regression worth forcing right now'. 'Force' and 'Unforce' ask for confirmation each time: Force makes Query Store pin that plan for the query and can be undone at any time; Unforce lets the optimizer choose plans freely again. If the forced plan cannot be applied the screen shows 'Plan N was not forced' and the reason. This is a real change on the server: it needs Admin or DBA, and should be used only after comparing the plans and seeing that the old plan is really better.

  5. Step 5: Observe → Performance Analyzer → MSSQL → Queries

    Do

    In the drawer go down to 'Contention & Waits', 'Time Trends' and 'Recommended Actions'. In Time Trends use the window (1h, 6h, 24h, 7d) and, if needed, the 'vs yesterday' or 'vs last week' option next to 'Compare: off'.

    Look for

    In Contention & Waits 'Actively blocking N session(s)' / 'Waiting on a lock held elsewhere.' and wait-type bars (it may read 'No wait correlation yet — requires Query Store on this database ...'). In Time Trends the Avg Duration, CPU / Exec, Reads / Exec and Execution Count charts; on the Avg Duration chart a dashed vertical line at each plan change with a 'plan change' or 'plan ±N%' label; a dashed reference line when the comparison is on. In Recommended Actions the Safe/Investigate items.

    How to read it

    The vertical line on the Avg Duration chart marks the moment of the plan change; the percentage in its label (like 'plan +34%') compares the mean in the 10 minutes before and after the change; unless both sides have at least 2 samples, or the difference is under 10%, only 'plan change' is printed. If the jump starts right after the line, the plan change is a strong candidate; if the jump started at an unrelated moment, look at Contention & Waits, at the load growth in the Execution Count chart and at the instance tiles from step 1. Comparing the same window with 24 hours or 7 days earlier answers 'is this normal'. The items in the 'Execution plan' section and in 'Recommended Actions' are suggestions only; if locks are involved move to the 'Blocking and deadlocks in SQL Server: who is holding whom' guide. 'AI Query Assist' in the 'AI Analysis' section sends the query, plan and live schema to the AI for a rewrite suggestion (it needs an Enterprise licence) and only produces a suggestion; it applies nothing.

Outcome

By the end you know whether the slowdown came from a plan change (through the old versus new plan comparison of duration, CPU and reads), from rising load, or from waits and blocking. All of the reading screens are read-only. The only change ClusterEye can make in this guide is Plan Forcing in the Compare Plans window: it pins a plan for the query through Query Store (Force) or removes the pin (Unforce). It asks for confirmation each time, never runs automatically and needs the Admin or DBA role. Adding an index, updating statistics or rewriting the query is not applied from ClusterEye.

Performance
Blocking and deadlocks in SQL Server: who is holding whom

On the Deadlocks & Blocking tab read who is holding whom right now, the recorded blocking episodes and the recurring deadlock patterns; on the Transactions tab check open transactions and the log and version store impact; if needed terminate the lead blocker session.

Performance
A slow query in PostgreSQL: finding it and reading its plan and load

On the Queries tab of PostgreSQL Performance Analytics find the slow or heavy query with the modes and columns, read its impact breakdown, suggestions, execution plan and time trend in the drawer, and use AI Query Assist when needed.

Incident response
Alarm triage: finding, owning, snoozing and resolving an alarm

On the Alarms page prioritise active alarms, read an alarm's detail, acknowledge and own it, snooze it or silence it with a maintenance window when needed, and close it as resolved.

Incident response
What happened last night: reading incidents and root cause on the Timeline

On the Timeline page narrow the last 24 hours by severity, read an incident's root-cause summary and story, drill into raw events and, if needed, get a plain-language account with AI Explain.