SQL Interview & Case Lab
Back to Performance & Query Reading

The 5 Most Common Reasons Your SQL Is Slow

Walk through the five patterns that account for ~80% of slow analyst queries. FIND_VIDEO: search 'why is my SQL query slow common reasons' — recommended channel: EverSQL / Crunchy Data. Aim for 11 min or under.

24 minutesVideo LessonPDF notes
🎯 Free Guest Mode: You are learning for free. Sign in to save your completion progress and quiz answers.
Loading progress...

Key moments

  1. Remote DAC Purpose — Darling introduces the Dedicated Admin Connection for querying SQL Server during severe performance catastrophes.
  2. Reboot Forensics Impact — Darling explains how restarting the instance destroys essential DMV troubleshooting metrics and diagnostic logs.
  3. Troubleshooting Scope — Darling outlines the top five common performance issues while excluding sudden AG failovers and statistics updates.
  4. CPU and Thread Pool — Darling triggers thread exhaustion to demonstrate THREADPOOL waits and query downgrades to single-threaded DOP 1.
  5. Memory Grant Pressure — Darling explains memory grant allocation caps and demonstrates how sorting and hashing trigger RESOURCE_SEMAPHORE waits.
  6. Runaway Maintenance — Darling critiques unnecessary daytime index rebuilds and highlights the impact of unmanaged maintenance operations.
PDF notes

Frequently asked questions

Why does restarting SQL Server make root-cause analysis nearly impossible?

Restarting flushes the plan cache, memory clerks, active DMV wait statistics, and queued execution contexts needed for diagnostic forensics.

What happens to parallel queries when available worker threads are exhausted?

SQL Server downgrades parallel queries to execute at DOP 1, running a parallel execution plan shape on a single thread.

What operations request query memory grants that trigger RESOURCE_SEMAPHORE waits?

Memory grants are requested primarily by sorting, hashing, and batch mode operations before query execution begins.

Why shouldn't monitoring tools connect through the remote DAC?

The DAC supports only a single concurrent connection, and dedicating it to a tool locks administrators out during severe outages.

How was this lesson?

Your feedback helps us refine explanations and catch bugs.