欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  数据库

查询从未使用的索引

程序员文章站 2022-06-01 22:56:19
...

查询从未使用的索引 无 select object_name(object_id),* sys.dm_db_index_usage_state where user_seeks=0 and user_scans=0 and user_lookups=0 and system_seeks=0 and system_scans=0 and system_lookups=0 and object_name(object_id) is not null

查询从未使用的索引
select object_name(object_id),* sys.dm_db_index_usage_state where user_seeks=0 and user_scans=0 and user_lookups=0 and system_seeks=0 and system_scans=0 and system_lookups=0 and object_name(object_id) is not null