QUOTE(baavgai @ 29 Apr, 2008 - 05:40 AM)

You've got one of the data dictionary tables. There are more. This should get you what you need:
CODE
SELECT so.name table_name,
si.name AS index_name,
sik.indid, sik.colid, sik.keyno,
sc.name AS column_name
FROM sysobjects so
INNER JOIN sysindexes si
ON so.id = si.id
INNER JOIN sysindexkeys sik
ON si.id = sik.id
AND si.indid = sik.indid
INNER JOIN syscolumns sc
ON sik.id = sc.id
AND sik.colid = sc.colid
WHERE so.xtype='U'
AND so.name='tablename'
ORDER BY so.name, si.name, sik.keyno
Hope this helps.
Thanks you so much for your early reply dear. I did get my answer through your query, but I used the system stored procedure sp_helpindex 'tablename' and it fetched me exactly what I wanted. Once again thanks a lot.
"Life's never too tough or easy only we make it so..."