This month's discount Comprehensive Database Performance Health Check · Testimonials
SQLAuthority with Pinal Dave
Home
  • Consulting
    • Health Check
  • Free Videos
  • All Articles
    • AI
    • SQL Performance
    • SQL Tips and Tricks
    • Interview Questions and Answers
    • SQL Puzzle
    • SQL Video
    • SQLAuthority News
    • Personal
  • Books
  • Consulting
Gouache painting of a pantry shelf of jars with uneven gaps beside a snug shelf, with one vermilion jar alone

Check Index Fragmentation With Row Count in SQL Server

October 17, 2019
Pinal Dave
SQL Performance
Clustered Index, SQL Index, SQL Scripts, SQL Server

To check index fragmentation with row count, read sys.dm_db_index_physical_stats in SAMPLED mode and keep the page count and row count next to each percentage. This post builds a demo with three tables, lists every index, filters out the tiny ones, loops over every online database, and rebuilds the one index that matters.

Read More
Two gaskets beside a pipe flange being checked for fit and thickness

Index Size Estimate: Sizing an Index Before You Create It

January 17, 2019
Pinal Dave
SQL Performance
Clustered Index, ColumnStore Index, SQL Index

Before you build an index, estimate its size and say what you assumed. Then check the guess against real pages on a copy.

Read More
Execution Plan Cost Breakdown.

SQL SERVER – Parallelism for Heap Scan

October 29, 2018
Pinal Dave
SQL Performance
Clustered Index, Parallel, SQL CPU, SQL Heap, SQL Index, SQL Scripts, SQL Server

Two DBAs asked me if their table needed a clustered index. Our conversation during a Health Check turned into a lesson on parallelism for Heap Scan.

Read More
A shoulder yoke carrying one bucket of stones while a second load waits beside it

Disk Space Needed to Build a Clustered Index on a Big Table

April 11, 2018
Pinal Dave
SQL Performance
Clustered Index, SQL Table Operation, Table Partitioning, Temp Table

A clustered index build holds the old table and the new index at the same time. Here is a small demo of that peak, and what to check first.

Read More
Forwarded Records Impact Count and Pages.

SQL SERVER – What is Forwarded Records and How to Fix Them?

March 8, 2018
Pinal Dave
SQL Tips and Tricks
Clustered Index, SQL Heap, SQL Index, SQL Scripts, SQL Server

Forwarded Records in heap tables still puzzle many SQL Server users, years after I first wrote about them. Here is what they are and how to fix them.

Read More
Different mechanical gear types surround one table-like central hub

How to List All the Nonclustered Indexes of Your Table? – Interview Question of the Week #155

January 7, 2018
Pinal Dave
SQL Interview Questions and Answers
Clustered Index, ColumnStore Index, SQL Index, SQL Scripts, SQL Server

How do you list all the clustered and nonclustered indexes of your table, including columnstore? Here is the script I use in my performance health checks.

Read More
Different column structures are cataloged in a single orderly stone rack

How to List All ColumnStore Indexes with Table Name in SQL Server? – Interview Question of the Week #153

December 24, 2017
Pinal Dave
SQL Interview Questions and Answers
Clustered Index, ColumnStore Index, SQL DMV, SQL Index, SQL Scripts, SQL Server

Question: How to List All ColumnStore Indexes with Table Name in SQL Server? As ColumnStore Indexes are getting more and more popular.

Read More
Previous 1 2 3 4 5 6 7 8 Next
  • Books
  • Testimonials
  • Privacy Policy

© 2006 – 2026 All rights reserved. pinal @ SQLAuthority.com