Question of the Day Two
Today we continue our series with our second question of the day.
What is the difference between a clustered and non-clustered index?
In simplest terms, a clustered index is the actual data, reordering the way that the records are physically stored. Because of this, each table can only contain one clustered index.
However, a non-clustered index is more like a pointer to the actual record. The logical order of the non-clustered index does not usually match how the data is stored physically.
There is also a third option, the heap, which is a table without an index at all. Without an index, the server would have to read through all of the records in order to find the data queried. Enjoy!
Posted on August 4, 2012, in SQL Schoolhouse and tagged SQL Learning. Bookmark the permalink. Leave a comment.
Leave a comment