All Products
Search
Document Center

AnalyticDB:DescribeTablePartitionDiagnose

Last Updated:Nov 10, 2025

Queries the information about partition diagnostics.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • For mandatory resource types, indicate with a prefix of * .
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
adb:DescribeTablePartitionDiagnoseget
DBClusterLakeVersion
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
DBClusterIdstringYes

The cluster ID.

amv-bp171g24yvbxxxxx
PageSizeintegerNo

The number of entries per page.

30
PageNumberintegerNo

The page number.

1
OrderstringNo

The order by which to sort query results. Specify the parameter value in the JSON string format. Example: [{"Field":"TotalSize","Type":"Desc"}].

  • Field specifies the field by which to sort the query results. Valid values:

    • SchemaName: the name of the database to which the table belongs.
    • TableName: the name of the table.
    • TotalSize: the total data size of the table.
    • SpaceRatio: the storage percentage of the table.
  • Type specifies the sorting order. Valid values:

    • Asc: ascending order.
    • Desc: descending order.
Note If you do not specify this parameter, the query results are sorted by the TotalSize field in descending order.
[{\"Field\":\"TotalSize\",\"Type\":\"Desc\"}]
RegionIdstringYes

The region ID.

cn-hangzhou
LangstringNo

The language of the content within the request and response. Default value: zh. Valid values:

  • zh: simplified Chinese.
  • en: English.
  • ja: Japanese.
  • zh-tw: traditional Chinese.
zh

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

TotalCountinteger

The total number of entries returned.

185
RequestIdstring

The request ID.

1AD222E9-E606-4A42-BF6D-8A4442913CEF
PageSizeinteger

The number of entries per page.

30
PageNumberinteger

The page number.

1
DBClusterIdstring

The cluster ID.

amv-bp171g24yvbxxxxx
SuggestMaxRecordsPerPartitionlong

The recommended maximum number of rows in each partition.

640000000
SuggestMinRecordsPerPartitionlong

The recommended minimum number of rows in each partition.

64000000
Itemsarray<object>

The queried partition diagnostic information.

TablePartitionDiagnoseobject

The queried partition diagnostic information.

TableNamestring

The name of the table.

user
PartitionDetailstring

The improper partitions.

[20210110, 20210113,20210123]
SchemaNamestring

The name of the database.

test_db
PartitionNumberinteger

The number of partitions.

2
TotalSizelong

The total data size of the table. Unit: bytes.

42949672960
SpaceRatiodouble

The storage percentage of the table. Unit: %.

Note Formula: Table storage percentage = Total data size of a table/Total data size of the cluster × 100%.
66.23
DetectionItemsarray<object>

The queried detection items and detection results.

DetectionItemsobject

The queried detection item and detection result.

Namestring

The name of the detection item.

Improper partition field diagnostics
Messagestring

The detection result.

Multiple oversized non-partitioned tables are detected.
Statusstring

The severity level of the detection result. Valid values:

  • NORMAL
  • WARNING
  • CRITICAL
WARNING
AccessDeniedDetailstring

The information about the request denial.

{ "PolicyType": "AccountLevelIdentityBasedPolicy", "AuthPrincipalOwnerId": "1*****************7", "EncodedDiagnosticMessage": "AQIBIAAAAOPdwKY2QLOvgMEc7SkkoJfj1kvZwsaRqNYMh10Tv0wTe0fCzaCdrvgazfNb0EnJKETgXyhR+3BIQjx9WAqZryejBsp1Bl4qI5En/D9dEhcXAtKCxCmE2kZCiEzpy8BoEUt+bs0DmlaGWO5xkEpttypLIB4rUhDvZd+zwPg4EXk4KSSWSWsurxtqDkKEMshKlQFBTKvJcKwyhk62IeYly4hQ+5IpXjkh1GQXuDRCQ==", "AuthPrincipalType": "SubUser", "AuthPrincipalDisplayName": "2***************9", "NoPermissionType": "ImplicitDeny", "AuthAction": "adb:DescribeExcessivePrimaryKeys" }

Examples

Sample success responses

JSONformat

{
  "TotalCount": 185,
  "RequestId": "1AD222E9-E606-4A42-BF6D-8A4442913CEF",
  "PageSize": 30,
  "PageNumber": 1,
  "DBClusterId": "amv-bp171g24yvbxxxxx",
  "SuggestMaxRecordsPerPartition": 640000000,
  "SuggestMinRecordsPerPartition": 64000000,
  "Items": [
    {
      "TableName": "user",
      "PartitionDetail": [
        20210110,
        20210113,
        20210123
      ],
      "SchemaName": "test_db",
      "PartitionNumber": 2,
      "TotalSize": 42949672960,
      "SpaceRatio": 66.23
    }
  ],
  "DetectionItems": [
    {
      "Name": "Improper partition field diagnostics",
      "Message": "Multiple oversized non-partitioned tables are detected.",
      "Status": "WARNING"
    }
  ],
  "AccessDeniedDetail": {
    "PolicyType": "AccountLevelIdentityBasedPolicy",
    "AuthPrincipalOwnerId": "1*****************7",
    "EncodedDiagnosticMessage": "AQIBIAAAAOPdwKY2QLOvgMEc7SkkoJfj1kvZwsaRqNYMh10Tv0wTe0fCzaCdrvgazfNb0EnJKETgXyhR+3BIQjx9WAqZryejBsp1Bl4qI5En/D9dEhcXAtKCxCmE2kZCiEzpy8BoEUt+bs0DmlaGWO5xkEpttypLIB4rUhDvZd+zwPg4EXk4KSSWSWsurxtqDkKEMshKlQFBTKvJcKwyhk62IeYly4hQ+5IpXjkh1GQXuDRCQ==",
    "AuthPrincipalType": "SubUser",
    "AuthPrincipalDisplayName": "2***************9",
    "NoPermissionType": "ImplicitDeny",
    "AuthAction": "adb:DescribeExcessivePrimaryKeys"
  }
}

Error codes

For a list of error codes, visit the Service error codes.