Tuesday, March 20, 2012

Primary Key Column

Does position of primary key column in a table has impact on perfromance ? I
have always used first column(or columns) for primary key. I am looking at a
system right now which has primary keys defined in the middle or end of
table. Does it impact performance ?
Any help is appreciated. Thanks.
No impact. What has impact is what indexes you have and how they are defined. And remember that a PK
definition creates a unique index (by default as a clustered index).
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
"B2" <B2@.discussions.microsoft.com> wrote in message
news:D6C7E1FB-CAAF-4275-9FBF-F5C6F235B2E0@.microsoft.com...
> Does position of primary key column in a table has impact on perfromance ? I
> have always used first column(or columns) for primary key. I am looking at a
> system right now which has primary keys defined in the middle or end of
> table. Does it impact performance ?
> Any help is appreciated. Thanks.
>

No comments:

Post a Comment