Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Primary keys and clustered indexes
Message
From
29/06/2006 19:21:37
 
 
To
29/06/2006 19:13:21
General information
Forum:
Microsoft SQL Server
Category:
Database design
Miscellaneous
Thread ID:
01132920
Message ID:
01132948
Views:
12
Thanks Perry...

Isn't the table in the same order for both option 2 and 3?


>I sit next to a DBA now. I asked him. He reccommended option 3. So selects will be much faster, since the table will be in that order.
>
>>Some options I see for the detal table:
>>
>>1) primary key: lineID, but with a non-clustered index. clustered index on invoiceID.
>>
>>2) primary key: lineID, but with a non-clustered index. A clustered index on invoiceID + lineID.
>>
>>3) primary key: invoiceID + lineID, with clustered index on the combination.
>>
Steve Gibson
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform