[SQL Server] In-Memory OLTP : Afficher le nombre de compartiments et les chaînes de lignes des index de hachage
select
T4.name + '.' + T2.name as [Table]
,T3.name as [Index]
,T1.total_bucket_count as [Total Buckets]
,T1.empty_bucket_count as [Empty Buckets]
,floor(100. * empty_bucket_count / total_bucket_count)
as [Empty Bucket %]
,T1.avg_chain_length as [Avg Chain]
,T1.max_chain_length as [Max Chain]
from sys.dm_db_xtp_hash_index_stats T1
join sys.tables T2 on T1.object_id = T2.object_id
join sys.indexes T3 on T1.object_id = T3.object_id and
T1.index_id = T3.index_id join sys.schemas T4 on T2.schema_id = T4.schema_id