O'Reilly logo

Microsoft® SQL Server 2008 R2 Unleashed by Alex T. Silverstein, Chris Gallelli, Paul Bertucci, Ray Rankins

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Wide Indexes Versus Multiple Indexes

As an index key gets wider, the selectivity of the key generally becomes higher as well. It might seem that creating wide indexes would result in better performance. This is not necessarily true. The reason is that the wider the key, the fewer rows SQL Server stores on the index pages, requiring more pages at each level; this results in a higher number of levels in the index B-tree. To get to specific rows, SQL Server must perform more I/O.

To get better performance from queries, instead of creating a few wide indexes, you should consider creating multiple narrower indexes. The advantage here is that with smaller keys, the Query Optimizer can quickly scan through multiple indexes to determine the most efficient ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required