sp_indexes (Transact-SQL)
Returns index information for the specified remote table.
Column name | Data type | Description |
|---|---|---|
TABLE_CAT | sysname | Name of the database in which the specified table resides. |
TABLE_SCHEM | sysname | Schema for the table. |
TABLE_NAME | sysname | Name of the remote table. |
NON_UNIQUE | smallint | Whether the index is unique or not unique: 0 = Unique 1 = Not unique |
INDEX_QUALIFER | sysname | Name of the index owner. Some DBMS products allow for users other than the table owner to create indexes. In SQL Server, this column is always the same as TABLE_NAME. |
INDEX_NAME | sysname | Name of the index. |
TYPE | smallint | Type of index: 0 = Statistics for a table 1 = Clustered 2 = Hashed 3 = Other |
ORDINAL_POSITION | int | Ordinal position of the column in the index. The first column in the index is 1. This column always returns a value. |
COLUMN_NAME | sysname | Is the corresponding name of the column for each column of the TABLE_NAME returned. |
ASC_OR_DESC | varchar | Is the order used in collation: A = Ascending D = Descending NULL = Not applicable SQL Server always returns A. |
CARDINALITY | int | Is the number of rows in the table or unique values in the index. |
PAGES | int | Is the number of pages to store the index or table. |
FILTER_CONDITION | nvarchar(4000) | SQL Server does not return a value. |
