title | description | author | ms.author | ms.date | ms.service | ms.subservice | ms.topic | dev_langs | monikerRange | |
---|---|---|---|---|---|---|---|---|---|---|
DBCC PDW_SHOWPARTITIONSTATS (Transact-SQL) |
DBCC PDW_SHOWPARTITIONSTATS displays the size and number of rows for each partition of a table in Azure Synapse Analytics or Analytics Platform System (PDW). |
rwestMSFT |
randolphwest |
12/05/2022 |
sql |
data-warehouse |
reference |
|
>= aps-pdw-2016 || = azure-sqldw-latest |
[!INCLUDEapplies-to-version/asa-pdw]
Displays the size and number of rows for each partition of a table in a [!INCLUDEssazuresynapse-md] or [!INCLUDEssPDW] database.
:::image type="icon" source="../../includes/media/topic-link-icon.svg" border="false"::: Transact-SQL syntax conventions
--Show the partition stats for a table
DBCC PDW_SHOWPARTITIONSTATS ( "[ database_name . [ schema_name ] . ] | [ schema_name. ] table_name" )
[;]
Note
[!INCLUDEsynapse-analytics-od-unsupported-syntax]
The one, two, or three-part name of the table to be displayed. For two or three-part table names, the name must be enclosed with double quotes (""). Using quotes around a one-part table name is optional.
Requires VIEW SERVER STATE permission.
This set is the results for the DBCC PDW_SHOWPARTITIONSTATS
command.
Column name | Data type | Description |
---|---|---|
partition_number | int | Partition number. |
used_page_count | bigint | Number of pages used for the data. |
reserved_page_count | bigint | Number of pages reserved for the partition. |
row_count | bigint | Number of rows in the partition. |
pdw_node_id | int | Compute node for the data. |
distribution_id | int | Distribution identifier for the data. |
Examples: [!INCLUDEssazuresynapse-md] and [!INCLUDEssPDW]
The following examples display the space used and number of rows by partition for the FactInternetSales
table in the [!INCLUDEssawPDW] database.
DBCC PDW_SHOWPARTITIONSTATS ("ssawPDW.dbo.FactInternetSales");
DBCC PDW_SHOWPARTITIONSTATS ("dbo.FactInternetSales");
DBCC PDW_SHOWPARTITIONSTATS (FactInternetSales);