ColumnCount property

Returns the number of columns in the index.

Syntax
Visual Basic

Public Readonly Property ColumnCount As Short
C#

public short ColumnCount  { get;}
Property value

The number of columns in the index.

Remarks

Column ordinals in indexes range from 1 to ColumnCount, inclusive.

Column ordinals and count may change during a schema upgrade. Column ordinals from an index are different than the column IDs in a table or another index, even if they refer to the same physical column in a particular table.

See also