20

I have created an index in Oracle SQl-

create index ind_cname on country(capital)

When executed I got a success message.Now I want to see the created Index. Please help in the syntax to show index.

I am new to Oracle .I want a query which shows indexes for the table.

Thanks

ratr
  • 606
  • 1
  • 9
  • 24

1 Answers1

49

If you have the privileges, you can use the ALL_INDEXES or USER_INDEXES views. The query would be:

SELECT  *
FROM    all_indexes
WHERE   table_name = 'COUNTRY';

If you want some information on the columns included in the index, you can select those from ALL_IND_COLUMNS. Documentation regarding these views can be found here Static Data Dictionary Views: ALL_ALL_TABLES to ALL_MVIEWS

v8-E
  • 1,077
  • 2
  • 14
  • 21
Entalyan
  • 891
  • 8
  • 6