共用方式為


Clustered Property

未來的 Microsoft SQL Server 發行版本將不再提供此功能。請避免在新的開發工作中使用此功能,並計劃修改目前使用此功能的應用程式。

The Clustered property reports index clustering on Microsoft SQL Server primary keys.

語法


            object
            .Clustered [=value]

Parts

  • object
    An expression that evaluates to an object in the Applies To list
  • value
    TRUE or FALSE

Data Type

Boolean

Modifiable

Read/write before the SQL Server primary key is created. Read-only if the Key object references an existing primary key.

Prototype (C/C++)

HRESULT GetClustered(LPBOOL pRetVal);
HRESULT SetClustered(BOOL NewValue);

備註

The Clustered property has meaning if the Key object references a SQL Server table primary key. If the Key object references a foreign key, the value is always FALSE.

If TRUE, the referenced primary key either has, or will be created with, a clustered index supporting it.

If FALSE, the referenced primary key has, or will be created with, a nonclustered index. The default for new Key objects is FALSE.

Applies To:

Key Object