Queries the details about slow query logs.
Debugging
Authorization information
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionId | string | Yes | The region ID. You can call the DescribeRegions operation to query the most recent region list. | cn-hangzhou |
DBClusterId | string | Yes | The cluster ID. You can call the DescribeDBClusters operation to query information about all the clusters that are deployed in a specific region. The information includes the cluster IDs. | cc-bp1z58t881wcx**** |
StartTime | string | Yes | The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-dd hh:mm:ss format. The time must be in Coordinated Universal Time (UTC). | 2022-05-20 16:00:00 |
EndTime | string | Yes | The end of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-dd hh:mm:ss format. The time must be in UTC. Note
The end time must be later than the start time. The specified time range that can be specified must be less than seven days.
| 2022-05-27 16:00:00 |
PageSize | integer | No | The number of entries per page. Valid values:
| 30 |
PageNumber | integer | No | The page number. Pages start from page 1. Default value: 1. | 1 |
QueryDurationMs | integer | No | The minimum query duration. The minimum value is 1000, and the default value is 1000. Unit: milliseconds. Queries that last longer than this duration are returned in response parameters. | 1000 |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "DF203CC8-5F68-5E3F-8050-3C77DD65731A",
"SlowLogRecords": {
"TableSchema": {
"ResultSet": [
{
"Type": "String",
"Name": "name"
}
]
},
"Data": {
"ResultSet": [
{
"Type": "QueryFinish",
"QueryStartTime": "2022-05-22 20:00:01",
"Query": "Select * from table",
"ReadRows": "10027008",
"InitialAddress": "::ffff:100.104.XX.XX",
"MemoryUsage": "1048576",
"InitialUser": "test_users",
"InitialQueryId": "'b51496f2-6b0b-4546-aff9-e17951cb9410'",
"ReadBytes": "1048576",
"QueryDurationMs": "2000",
"ResultBytes": "1024"
}
]
},
"Rows": "1",
"RowsBeforeLimitAtLeast": "1",
"Statistics": {
"RowsRead": 2016722,
"ElapsedTime": 21.35,
"BytesRead": 123456
}
}
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
500 | InternalError | An error occurred while processing your request. | An error occurred while processing your request. |
503 | ServiceUnavailable | An error occurred while processing your request. | An error occurred while processing your request. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|