All Products
Search
Document Center

AnalyticDB:DescribeExcessivePrimaryKeys

Last Updated:Jan 24, 2025

Queries the tables that have excessive primary key fields in an AnalyticDB for MySQL Data Warehouse Edition (V3.0) cluster.

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:DescribeExcessivePrimaryKeysget
*DBClusterLakeVersion
acs:adb:{#regionId}:{#accountId}:dbcluster/{#DBClusterId}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
DBClusterIdstringYes

The cluster ID.

Note You can call the DescribeDBClusters operation to query the IDs of all AnalyticDB for MySQL Data Warehouse Edition (V3.0) clusters within a region.
am-bp1u8c0mgfg58****
RegionIdstringYes

The region ID of the cluster.

Note You can call the DescribeRegions operation to query the most recent region list.
cn-beijing
StartTimestringYes

The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

2021-09-30T00:10Z
EndTimestringYes

The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.

2023-05-15T07:15Z
PageSizeintegerNo

The number of entries per page. Valid values:

  • 30 (default)
  • 50
  • 100
20
PageNumberintegerNo

The page number. Pages start from page 1. Default value: 1.

1
LangstringNo

The display language of the suggestion. Valid values:

  • zh (default): simplified Chinese.
  • en: English.
  • ja: Japanese.
  • zh-tw: traditional Chinese.
zh
OrderstringNo

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

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

    • TableSchema: the name of the database to which the table belongs.
    • TableName: the name of the table.
    • AccessCount: the number of accesses to the table.
  • Type specifies the sorting order. Valid values:

    • Asc: ascending order.
    • Desc: descending order.
Note If you do not specify this parameter, query results are sorted in ascending order based on the database and the table.
[{"Field":"TableName","Type":"Desc"}]

Response parameters

ParameterTypeDescriptionExample
object
TotalCountstring

The total number of entries returned.

1
PageNumberinteger

The page number. Pages start from page 1. Default value: 1.

1
PageSizeinteger

The number of entries per page. Valid values:

  • 30 (default)
  • 50
  • 100
10
RequestIdstring

The request ID.

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

The cluster ID.

Note You can call the DescribeDBClusters operation to query the IDs of all AnalyticDB for MySQL Data Warehouse Edition (V3.0) clusters within a region.
am-bp11q28kvl688****
Tablesarray<object>

The queried tables.

ExcessivePrimaryKeyInfosobject
TableNamestring

The name of the table.

test
SchemaNamestring

The name of the database.

adb_demo
ColumnCountinteger

The total number of columns.

26
PrimaryKeyCountinteger

The number of primary key fields.

1
PrimaryKeyColumnsstring

The queried primary key fields.

id,date
SpaceRatiodouble

The percentage of the table size. Unit: %.

Note Formula: Table storage percentage = Total data size of a table/Total data size of the cluster × 100%.
20
TotalSizelong

The cold data size. Unit: bytes.

Note Formula: Cold data size = Data size of table records + Data size of regular indexes + Data size of primary key indexes + Size of other data.
1073741824
PrimaryKeyIndexSizelong

The data size of primary key indexes. Unit: bytes.

2345
DetectionItemsarray<object>

The queried detection items and detection results.

DetectionItemsArrayobject
Namestring

The name of the detection item.

evm_identity
Messagestring

The detection result.

OK
Statusstring

The severity level of the detection result.

NORMAL WARNING CRITICAL
AccessDeniedDetailstring

The details about the access denial.

Note This parameter is returned only if Resource Access Management (RAM) permission verification failed.
{ "PolicyType": "AccountLevelIdentityBasedPolicy", "AuthPrincipalOwnerId": "1906102576997697", "EncodedDiagnosticMessage": "AQIBIAAAAOPdwKY2QLOvgMEc7SkkoJfj1kvZwsaRqNYMh10Tv0wTe0fCzaCdrvgazfNb0EnJKETgXyhR+3BIQjx9WAqZryejBsp1Bl4qI5En/D9dEhcXAtKCxCmE2kZCiEzpy8BoEUt+bs0DmlaGWO5xkEpttypLIB4rUhDvZd+zwPg4EXk4KSSWSWsurxtqDkKEMshKlQFBTKvJcNqPqHV6lwR4INiAGjIvK1ngXxN1O+6ORRB6A8YvztEOGywOk81ZmuNk0YrNy+qk7+UVDTHeXKsy8h9e/ePY/LMidj0RCmDpo/YpCumd0UGe0qEPe2U+UJAm/+UHlnEFLVg6BP3yIB5D++MCy7mgWm8Kwyhk62IeYly4hQ+5IpXjkh1GQXuDgLVVPVpxEek9n30vnCUL4KsaMgfa7dgojb+3TM8xGsD2zVK5STJNrsXclscIJEqyNXd7CBYiRJVZi1HPO6drN9WW0chLpCSTgjO8n0bNanZaxXKumW9PSwV58UoSFASeMWfZK3TLngX+oq8nGmnTwcJosVjfF4RGzAnS1IXt0Q9N2WHDnpwyLBU/nOz7Hsy8IZ+h+OVjsBTXSM9688/vOF707a5mNzpETvQeGRcua3A5livcKAM2cML0yeUs/Zyj/+BGqtVa+wektspDHC/CECh6R5lxQjRmUdPawY8VDs2onmdLuEH8DdmYt+Yv/jBFBUMWOyAluzkPYcX5nuQKouCIUJUFTSbsJsuH5CTIh7Ls5rbmkj+T1qTVz8gnDR8LxwaqoMSna+elXgVyOOxXtMkenVntsmoC3p/4G7yTPL1hu8JyWGIIvZHZGGLXGEH7FeSuMV8buKxPGFWG3arG8e9LGvDdz5dgTien4y6G5AQ0o1iQdXDos5VWdH3u7k5PrsvdEOpvMi6uSd8a42na80FsYlgGlwM5upydcWUC5Un2HCkJpT1xgk2L6shdVTrK6bidRrqE784FhW9bBQePzGaxSupPENZya0VUctRt+7uq3QwIn4y5jzjgX0E0jgmqPrgiVDjBesMQZYfGPCGysWYWYzfoh+G6V7N2VVGtNnGUwNWzM0WJBPONAgxPv+AmixFRCQ==", "AuthPrincipalType": "SubUser", "AuthPrincipalDisplayName": "202515810214480629", "NoPermissionType": "ImplicitDeny", "AuthAction": "adb:DescribeExcessivePrimaryKeys" }

Examples

Sample success responses

JSONformat

{
  "TotalCount": "1",
  "PageNumber": 1,
  "PageSize": 10,
  "RequestId": "1AD222E9-E606-4A42-BF6D-8A4442913CEF",
  "DBClusterId": "am-bp11q28kvl688****",
  "Tables": [
    {
      "TableName": "test",
      "SchemaName": "adb_demo",
      "ColumnCount": 26,
      "PrimaryKeyCount": 1,
      "PrimaryKeyColumns": "id,date",
      "SpaceRatio": 20,
      "TotalSize": 1073741824,
      "PrimaryKeyIndexSize": 2345
    }
  ],
  "DetectionItems": [
    {
      "Name": "evm_identity",
      "Message": "OK",
      "Status": "NORMAL\nWARNING\nCRITICAL"
    }
  ],
  "AccessDeniedDetail": "{\n    \"PolicyType\": \"AccountLevelIdentityBasedPolicy\",\n    \"AuthPrincipalOwnerId\": \"1906102576997697\",\n    \"EncodedDiagnosticMessage\": \"AQIBIAAAAOPdwKY2QLOvgMEc7SkkoJfj1kvZwsaRqNYMh10Tv0wTe0fCzaCdrvgazfNb0EnJKETgXyhR+3BIQjx9WAqZryejBsp1Bl4qI5En/D9dEhcXAtKCxCmE2kZCiEzpy8BoEUt+bs0DmlaGWO5xkEpttypLIB4rUhDvZd+zwPg4EXk4KSSWSWsurxtqDkKEMshKlQFBTKvJcNqPqHV6lwR4INiAGjIvK1ngXxN1O+6ORRB6A8YvztEOGywOk81ZmuNk0YrNy+qk7+UVDTHeXKsy8h9e/ePY/LMidj0RCmDpo/YpCumd0UGe0qEPe2U+UJAm/+UHlnEFLVg6BP3yIB5D++MCy7mgWm8Kwyhk62IeYly4hQ+5IpXjkh1GQXuDgLVVPVpxEek9n30vnCUL4KsaMgfa7dgojb+3TM8xGsD2zVK5STJNrsXclscIJEqyNXd7CBYiRJVZi1HPO6drN9WW0chLpCSTgjO8n0bNanZaxXKumW9PSwV58UoSFASeMWfZK3TLngX+oq8nGmnTwcJosVjfF4RGzAnS1IXt0Q9N2WHDnpwyLBU/nOz7Hsy8IZ+h+OVjsBTXSM9688/vOF707a5mNzpETvQeGRcua3A5livcKAM2cML0yeUs/Zyj/+BGqtVa+wektspDHC/CECh6R5lxQjRmUdPawY8VDs2onmdLuEH8DdmYt+Yv/jBFBUMWOyAluzkPYcX5nuQKouCIUJUFTSbsJsuH5CTIh7Ls5rbmkj+T1qTVz8gnDR8LxwaqoMSna+elXgVyOOxXtMkenVntsmoC3p/4G7yTPL1hu8JyWGIIvZHZGGLXGEH7FeSuMV8buKxPGFWG3arG8e9LGvDdz5dgTien4y6G5AQ0o1iQdXDos5VWdH3u7k5PrsvdEOpvMi6uSd8a42na80FsYlgGlwM5upydcWUC5Un2HCkJpT1xgk2L6shdVTrK6bidRrqE784FhW9bBQePzGaxSupPENZya0VUctRt+7uq3QwIn4y5jzjgX0E0jgmqPrgiVDjBesMQZYfGPCGysWYWYzfoh+G6V7N2VVGtNnGUwNWzM0WJBPONAgxPv+AmixFRCQ==\",\n    \"AuthPrincipalType\": \"SubUser\",\n    \"AuthPrincipalDisplayName\": \"202515810214480629\",\n    \"NoPermissionType\": \"ImplicitDeny\",\n    \"AuthAction\": \"adb:DescribeExcessivePrimaryKeys\"\n  }"
}

Error codes

HTTP status codeError codeError messageDescription
404InvalidDBCluster.NotFoundThe DBClusterId provided does not exist in our records.The specified DBClusterId parameter does not exist. Make sure that the DBClusterId value is valid.

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

Change history

Change timeSummary of changesOperation
No change history