SHOW INDexes
or SHOW INDICES
SHOW {INDexes | INDICES} [{table_name | index_name}]
You may specify either indexes
(or abbreviated forms starting with ind
) or indices
, they are treated as aliases by isql
.The first form of this command lists all user-defined indices in the current database.The second form of the command lists the indices of a specific table as determined by the table_name parameter.The final form of the command displays details of a specific index.
SQL> show indices; RDB$PRIMARY1 UNIQUE INDEX ON COUNTRY(COUNTRY) CUSTNAMEX INDEX ON CUSTOMER(CUSTOMER) ... SALESTATX INDEX ON SALES(ORDER_STATUS, PAID) SQL> show indices employee; NAMEX INDEX ON EMPLOYEE(LAST_NAME, FIRST_NAME) RDB$FOREIGN8 INDEX ON EMPLOYEE(DEPT_NO) RDB$FOREIGN9 INDEX ON EMPLOYEE(JOB_CODE, JOB_GRADE, JOB_COUNTRY) RDB$PRIMARY7 UNIQUE INDEX ON EMPLOYEE(EMP_NO) SQL> show index namex; NAMEX INDEX ON EMPLOYEE(LAST_NAME, FIRST_NAME)