Skip to content

Latest commit

 

History

History
19 lines (14 loc) · 471 Bytes

show_index.md

File metadata and controls

19 lines (14 loc) · 471 Bytes
  • 查看指定表格的索引使用show index命令:
show index from yourtable;
  • 要查看特定schema的所有表格的索引,从INFORMATION_SCHEMA查询STATISTICS表:
SELECT DISTINCT
    TABLE_NAME,
    INDEX_NAME
FROM INFORMATION_SCHEMA.STATISTICS
WHERE TABLE_SCHEMA = 'your_schema';

参考