Key Lookups and Index Creation

Erik Darling (Erik Darling Data)
774 views •

In this video, I delve into the intricacies of index creation and key lookups in SQL Server, using a practical example with the Stack Overflow database. I walk through the process of creating an index on the 'creation_date' column and adding a filter to it, highlighting the key lookup operation that occurs when no rows meet the filter criteria. I also discuss the impact of outdated statistics on query plans and index performance, emphasizing the importance of maintaining accurate statistics to avoid suboptimal execution plans. Along the way, I share some of my personal experiences and tips for tuning indexes, and I invite viewers to explore my free performance monitoring tools and consider becoming a channel supporter. CHAPTERS 00:00:00 - Introduction 00:01:30 - Index Creation and Key Lookups 00:04:28 - Query Plan Analysis 00:06:45 - Outdated Statistics Impact 00:09:16 - Key Lookup During Index Creation ━━━━━━━━━━━━━━━━━━━━━━━━━━ 🕵️‍♂️ FREE SQL SERVER MONITORING & Plan Analysis ━━━━━━━━━━━━━━━━━━━━━━━━━━ https://github.com/erikdarlingdata/PerformanceMonitor https://github.com/erikdarlingdata/PerformanceStudio https://plans.erikdarling.com/ ━━━━━━━━━━━━━━━━━━━━━━━━━━ 📚 TRAINING & COURSES ━━━━━━━━━━━━━━━━━━━━━━━━━━ Get AI-Ready With Erik https://training.erikdarling.com/get-ai-ready-with-erik?coupon=AIREADY SQL Server Performance Engineering Course https://training.erikdarling.com/sql-server-performance-engineering?coupon=ENGINEERING Learn T-SQL with Erik https://training.erikdarling.com/learn-t-sql-with-erik?coupon=ADVANCEDTSQL Everything Bundle: https://training.erikdarling.com/?coupon=SPRINGCLEANING ━━━━━━━━━━━━━━━━━━━━━━━━━━ 🛠️ CONSULTING & SERVICES ━━━━━━━━━━━━━━━━━━━━━━━━━━ Need SQL Server performance help? https://training.erikdarling.com/sqlconsulting ━━━━━━━━━━━━━━━━━━━━━━━━━━ 💬 CONNECT ━━━━━━━━━━━━━━━━━━━━━━━━━━ Ask questions at Office Hours https://erikdarling.com/officehours/ Become a channel member https://www.youtube.com/@ErikDarlingData/join

Keyboard shortcuts

On. Switch them off if they collide with your assistive tools; ? still opens this sheet.

Go to

Press g then the letter.

  • gh Latest
  • gs Sources
  • gm Media
  • gv Videos
  • gp Podcasts
  • gc Calendar
  • gd Decoder
  • gz Dataviz
  • ga Datasets
  • gb Blog
  • gk Markets
  • gj Careers
  • gn Prompt Notebook

On this page

  • / Focus search, where there is one
  • t Back to top
  • ? This list
  • Esc Close