August 2009
Intermediate to advanced
464 pages
13h 59m
English
Like the index at the end of this book, indexes within a database enable fast access to table contents. With each table in a SQL Server 2008 database supporting up to 1000 indexes, fast access can be enabled for a wide variety of lookups. However, as you'll soon see, poor index selection and maintenance can have the opposite effect, with reduced performance a common outcome.
It's possible (and common) for tables to be created without any indexes. Such tables are known as heaps. Before continuing, let's take a brief look at heaps.
Consider the script in listing 13.1, which creates a simple table and inserts five rows.
--a heap table and seed with data CREATE TABLE ... |
Read now
Unlock full access