三木会でデモしたクエリのメモ
select OBJECT_NAME(d.object_id) as table_name , ip.internal_object_type_desc , d.allocated_page_page_id as page_id , d.page_type , d.page_type_desc from sys.dm_db_database_page_allocations(db_id(), object_id('cci'), 1, null, 'DETAILED') d inner join sys.internal_partitions ip on d.rowset_id = ip.hobt_id and d.object_id = ip.object_id where ip.internal_object_type_desc = 'COLUMN_STORE_DELTA_STORE'
これでとれた page_id を 次のクエリに渡す。
dbcc traceon(3604) dbcc page('CCI_Sample', 1, 143616, 3) with tableresults dbcc traceoff(3604) select * from cci where c1 = 1000
テーブルデータと並べてみる。