摘要:
SELECTobject_name(a.object_id) [TableName],a.index_id,name [IndexName],avg_fragmentation_in_percentFROM sys.dm_db_index_physical_stats(DB_ID(), NULL, NULL, NULL, NULL) AS aJOIN sys.indexes AS bON a.ob... 阅读全文
摘要:
--Get Table usage spaceif object_id(N'tempdb..[#TableSizes]') is not null drop table #TableSizes ;/*——————————————&... 阅读全文