sp_helpindex System Stored Procedure

Reports information about the indexes on a table.

Syntax

sp_helpindex tabname

where

tabname
Specifies a table in the current database.

Remarks

Executing sp_helpindex lists up to eight indexes on a table.

Example

This example reports on the types of indexes on the sysobjects table.

sp_helpindex sysobjects
index_name
index_description
index_keys
---------------------
--------------------
---------------
sysobjects
clustered, unique
id
ncsysobjects
nonclustered, unique
name, uid


Permission

Execute permission defaults to the public group.

Tables Used

master.dbo.spt_values, sysindexes, syssegments

See Also

CREATE INDEX sp_statistics
DROP INDEX UPDATE STATISTICS
sp_help