Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 Get the list of all indexes in a database

Author  Topic 

sql_server_dba
Posting Yak Master

167 Posts

Posted - 2010-12-08 : 01:48:41
Hi All,

Is there anyway that we can get all the indexes in a database. I need tableName, indexName, clustered/nonClustered, unique/nonUnique, columns and some extra information if possible.

Thanks

GilaMonster
Master Smack Fu Yak Hacker

4507 Posts

Posted - 2010-12-08 : 02:52:41
Have a look at the sys.indexes view, join to sys.tables for the table name, sys.index_columns for the index columns.

--
Gail Shaw
SQL Server MVP
Go to Top of Page
   

- Advertisement -