Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Clustered Index internal structure

Will a clustered index in SQL Server 2008 R2 create an additional B-tree structure like in case of nonclustered index, where each element of the B-tree contains value and data locator?

Or SQL server just sorts all the table by the clustered index column?

like image 264
user2440447 Avatar asked Mar 03 '26 05:03

user2440447


1 Answers

Clustered Index by definition is the data and is stored with the index on disk in the order of the index itself. Instead of pointers to the data, the actual data is part of the index node.

http://msdn.microsoft.com/en-us/library/ms177443(v=sql.105).aspx

like image 56
Chris H Avatar answered Mar 05 '26 18:03

Chris H