sys.dm_db_column_store_row_group_operational_stats (Transact-SQL)sys.dm_db_column_store_row_group_operational_stats (Transact-SQL)

适用于: 是SQL Server是Azure SQL 数据库否Azure SQL 数据仓库否并行数据仓库APPLIES TO: yesSQL Server yesAzure SQL Database noAzure SQL Data Warehouse noParallel Data Warehouse

返回当前行级锁定,I/O 和访问方法活动为列存储索引中压缩行组。Returns current row-level I/O, locking, and access method activity for compressed rowgroups in a columnstore index. 使用sys.dm_db_column_store_row_group_operational_stats若要跟踪的时间长度用户查询必须等待读取或写入到压缩行组或分区中的列存储索引,并标识时遇到的行组大量 I/O 活动或热点。Use sys.dm_db_column_store_row_group_operational_stats to track the length of time a user query must wait to read or write to a compressed rowgroup or partition of a columnstore index, and identify rowgroups that are encountering significant I/O activity or hot spots.

在此 DMV 不会显示内存中列存储索引。In-memory columnstore indexes do not appear in this DMV.

列名Column name 数据类型Data type 描述Description
object_idobject_id intint 具有列存储索引的表的 ID。ID of the table with the columnstore index.
index_idindex_id intint columnstore 索引的 ID。ID of the columnstore index.
partition_numberpartition_number intint 索引或堆中从 1 开始的分区号。1-based partition number within the index or heap.
row_group_idrow_group_id intint 列存储索引中的 rowgroup 的 ID。ID of the rowgroup in the columnstore index. 这是在一个分区中是唯一的。This is unique within a partition.
scan_countscan_count intint 通过自上次 SQL 重新启动行组的扫描数。Number of scans through the rowgroup since the last SQL restart.
delete_buffer_scan_countdelete_buffer_scan_count intint 用于确定此行组中删除的行的删除缓冲区次数。Number of times the delete buffer was used to determine deleted rows in this rowgroup. 这包括访问内存中哈希表和基础的 b 树。This includes accessing the in-memory hashtable and the underlying btree.
index_scan_countindex_scan_count intint 列存储索引分区已扫描次数。Number of times the columnstore index partition was scanned. 这是相同的分区中的所有行组。This is the same for all rowgroups in the partition.
rowgroup_lock_countrowgroup_lock_count bigintbigint 自上次 SQL 重新启动此行组的锁请求的累积计数。Cumulative count of lock requests for this rowgroup since the last SQL restart.
rowgroup_lock_wait_countrowgroup_lock_wait_count bigintbigint 累积次数数据库引擎上等待此行组锁自上次 SQL 重新启动。Cumulative number of times the database engine waited on this rowgroup lock since the last SQL restart.
rowgroup_lock_wait_in_msrowgroup_lock_wait_in_ms bigintbigint 累积毫秒数的数据库引擎上等待此行组锁自上次 SQL 重新启动。Cumulative number of milliseconds the database engine waited on this rowgroup lock since the last SQL restart.


需要下列权限:Requires the following permissions:

  • 指定的 object_id 的表具有 CONTROL 权限。CONTROL permission on the table specified by object_id.

  • VIEW DATABASE STATE 权限,以返回有关在数据库中的所有对象的信息通过使用对象通配符 @object_id = NULLVIEW DATABASE STATE permission to return information about all objects within the database, by using the object wildcard @object_id = NULL

授予 VIEW DATABASE STATE 权限允许返回数据库中的所有对象,而不考虑对特定对象拒绝的任何 CONTROL 权限。Granting VIEW DATABASE STATE allows all objects in the database to be returned, regardless of any CONTROL permissions denied on specific objects.

拒绝 VIEW DATABASE STATE 将禁止返回数据库中的所有对象,而不管对特定对象授予的任何 CONTROL 权限。Denying VIEW DATABASE STATE disallows all objects in the database to be returned, regardless of any CONTROL permissions granted on specific objects. 此外,当数据库通配符 @database_id= 指定了 NULL,则省略数据库。Also, when the database wildcard @database_id=NULL is specified, the database is omitted.

有关详细信息,请参阅动态管理视图和函数(TRANSACT-SQL)For more information, see Dynamic Management Views and Functions (Transact-SQL).

请参阅See Also

动态管理视图和函数 (Transact-SQL) Dynamic Management Views and Functions (Transact-SQL)
与索引相关的动态管理视图和函数 (Transact-SQL) Index Related Dynamic Management Views and Functions (Transact-SQL)
监视和优化性能 Monitor and Tune for Performance
sys.dm_db_index_physical_stats (Transact-SQL) sys.dm_db_index_physical_stats (Transact-SQL)
sys.dm_db_index_usage_stats (Transact-SQL) sys.dm_db_index_usage_stats (Transact-SQL)
sys.dm_os_latch_stats (Transact-SQL) sys.dm_os_latch_stats (Transact-SQL)
sys.dm_db_partition_stats (TRANSACT-SQL) sys.dm_db_partition_stats (Transact-SQL)
sys.allocation_units (Transact-SQL) sys.allocation_units (Transact-SQL)
sys.indexes (Transact-SQL)sys.indexes (Transact-SQL)