Click or drag to resize

SA0050 : Do not create clustered index on UNIQUEIDENTIFIER columns

The topic describes the SA0050 analysis rule.

Message

Do not create clustered index on UNIQUEIDENTIFIER columns

Description

Consider moving the clustered index to a different column or consider using <codeInline>NewSequentialId()</codeInline> system function for generating sequential unique identifiers. The native <codeInline>uniqueidentifier</codeInline> data type is not suitable for clustered indexing, because causes terrible page splits because its value is completely random.

Scope

The rule has a ContextOnly scope and is applied only on current server and database schema.

Parameters

Rule has no parameters.

Remarks

The rule requires Analysis Context. If context is missing, the rule will be skipped during analysis.

Categories

Design Rules

Additional Information

There is no additional info for this rule.

See Also

Other Resources