Home Microsoft SQL Server DigiMailing iRN Contact



This is a view in the mssqlsystemresource database. Returns one row per partition in the database, showing page and row-count information for every partition in the current database, including the space used to store and manage in-row data, LOB data, and row-overflow data for all partitions in a database.

CREATE VIEW sys.dm_db_partition_stats AS
	SELECT c.partition_id, i.object_id, i.index_id, c.partition_number,
	c.in_row_data_page_count, c.in_row_used_page_count, c.in_row_reserved_page_count,
	c.lob_used_page_count, c.lob_reserved_page_count,
	c.row_overflow_used_page_count, c.row_overflow_reserved_page_count,
	c.used_page_count, c.reserved_page_count, c.row_count
	FROM sys.indexes$ i CROSS APPLY OpenRowSet(TABLE PARTITIONCOUNTS, i.object_id, i.index_id, i.rowset) c

Last revision 2008RTM
See also

  sp_estimate_data_compression_savings (Procedure)
sp_help_spatial_geography_index_helper (Procedure)
sp_help_spatial_geometry_index_helper (Procedure)
sp_MStable_validation (Procedure)
sp_spaceused (Procedure)
sp_table_validation (Procedure)


  Query a named instance
SQL 2008 R2
Deprecated procedures in SQL2008
Reporting Services item-level role definitions
Create all your missing indexes
Converting datetime field
Start MSSQL Server Profiler at time
Replicating MSSQL Server views
Exploring Microsoft Sharepoint
The OLE DB provider "SQLNCLI10" for linked server indicates.
Mobile solar charger
Oracle to SQL Server replication
Cannot insert the value NULL into column
Undocumented Microsoft SQL Server 2008
Zoekmachine optimalisatie
SQL Servers hidden objects
Flash in Ajax
De hype die AJAX heet
Barcode scannen
MySQL; Gratis, makkelijk en snel!
sIFR; de combinatie tussen HTML en Flash