All Products
Search
Document Center

ApsaraDB for OceanBase:DescribeOasSQLHistoryList

Last Updated:Feb 22, 2024

You can call this API to view the SQL execution history.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

There is currently no authorization information disclosed in the API.

Request parameters

ParameterTypeRequiredDescriptionExample
InstanceIdstringYes

The ID of the OceanBase cluster.

ob317v4uif****
TenantIdstringYes

The ID of the tenant.

t4louaeei****
StartTimestringYes

The start time of querying the execution history of the SQL statement.
The value must be UTC time in the format of YYYY-MM-DDThh:mm:ssZ.

2023-04-12T04:38:38Z
EndTimestringYes

The end time of querying the execution history of the SQL statement.
The value must be UTC time in the format of YYYY-MM-DDThh:mm:ssZ.

2023-04-12T05:38:38Z
DbNamestringNo

The name of the database.

test_db
SqlIdstringYes

SQL ID.

8D6E84****0B8FB1823D199E2CA1****
NodeIpstringNo

The IP address of the node.

i-bp19y05uq6x*********
AcceptLanguagestringNo

The language of the response. Valid values:

  • zh: Chinese
  • en: English
zh-CN

Response parameters

ParameterTypeDescriptionExample
object

Returned response.

RequestIdstring

The request ID.

EE205C00-30E4-****-****-87E3A8A2AA0C
Dataobject []

The list of SQL execution history.

SQLIdstring

SQL ID.

8D6E84****0B8FB1823D199E2CA1****
DbNamestring

The name of the database.

test_db
AvgAffectedRowslong

Average updated rows during the execution period.

9978.75
AvgBlockCacheHitlong

Average BlockCache hit count during the execution period.

0.0
AvgBlockIndexCacheHitlong

Average BlockIndexCache hit count during the execution period.

0.0
AvgBloomFilterCacheHitlong

Average BloomFilterCache hit count during the execution period.

0.0
Executionslong

Total number of executions during the execution period.

1
FailCountlong

The total number of errors during the execution period.

0
AvgRpcCountlong

Average number of RPC sent during the execution.

8.0
RemotePlanslong

Remote plan count.

0
MissPlanslong

Missed plan count.

0
AvgReturnRowslong

Average number of rows returned during the execution period.

0.0
AvgLogicalReadslong

Average logical reads during the execution period.

0.0
RetryCountlong

Total number of retries during the execution period.

0
AvgRowCacheHitlong

Average RowCache hit count during the execution period.

0.0
AvgDiskReadslong

Average physical read count during the execution period.

0.0
AvgMemstoreReadRowslong

Average Memstore read rows during the execution period.

0.0
AvgSsstoreReadRowslong

Average Ssstore read rows during the execution period.

0.0
AvgApplicationWaitTimedouble

Average Application event wait time (in milliseconds) during the client waiting period.

0.0
AvgElapsedTimedouble

Average response time (in milliseconds) during the execution period.

1876.78
AvgExecuteTimedouble

Average plan execution time (in milliseconds) during the execution period.

1895.7
AvgQueueTimedouble

Average queueing time (in milliseconds) during the execution period.

0.01
AvgConcurrencyWaitTimedouble

Average Concurrency event wait time (in milliseconds) during the execution period.

0.0
AvgCpuTimedouble

Average CPU time (in milliseconds) during the execution period.

1875.34
AvgDecodeTimedouble

Average syntax parsing time (in milliseconds) during the execution period.

0.0
AvgNetWaitTimedouble

Average network enqueue time (in milliseconds) during the network waiting period.

0.0
AvgUserIoWaitTimedouble

Average UserIO event wait time (in milliseconds) during the execution period.

0.0
AvgGetPlanTimedouble

Average plan generation time (in milliseconds) during the execution period.

0.0
MaxElapsedTimedouble

Max response time.

13643.3
SumWaitTimedouble

The total wait time (in milliseconds) during the internal waiting period.

9421.73
AvgScheduleTimedouble

Average Schedule event wait time (in milliseconds) during the scheduling period.

0.0
MaxCpuTimedouble

Max CPU time.

13641.9
SumElapsedTimedouble

Total response time (in milliseconds) during the execution period.

11452126.36
Timestampstring

Timestamp for the sample.

2023-04-12T04:46:38Z
Serverstring

The server where the SQL is executed.

i-bp1db1****8uemejio
UserNamestring

Username.

test_user
AvgPartitionCountdouble

Average number of partition accessed during the execution period.

1
FailPercentagedouble

Error percentage during the execution period.

0
RetCode4012Countdouble

Number of occurrences of code 4012 during the execution period.

0
RetCode4013Countdouble

Number of occurrences of code 4013 during the execution period.

0
RetCode5001Countdouble

Number of occurrences of code 5001 during the execution period.

0
RetCode5024Countdouble

Number of occurrences of code 5024 during the execution period.

0
RetCode5167Countdouble

Number of occurrences of code 5167 during the execution period.

0
RetCode5217Countdouble

Number of occurrences of code 5217 during the execution period.

0
RetCode6002Countdouble

Number of occurrences of code 6002 during the execution period.

0
AvgWaitTimedouble

Average wait time (in milliseconds) during the execution period.

1442.49
AvgWaitCountdouble

Average number of waits during the execution period.

0
LocalPlanPercentagedouble

Local plan percentage during the execution period.

0
RemotePlanPercentagedouble

Remote plan percentage during the execution period.

0
DistPlanPercentagedouble

Distributed plan percentage during the execution period.

100
AvgNetTimedouble

Average network transmission time (in milliseconds) during the execution period.

8
AvgExecutorRpcCountdouble

Average number of RPC requests executed during the execution period.

0
MissPlanPercentagedouble

Plan hit rage during the execution period.

0
TableScanPercentagedouble

Table scan percentage during the execution period.

0
StrongConsistencyPercentagedouble

Strong consistent transaction percentage during the execution period.

100
WeakConsistencyPercentagedouble

Eventually consistent transaction percentage during the execution period.

0
MaxAffectedRowsdouble

Max updated rows during the execution period.

10000
MaxReturnRowsdouble

Max returned rows during the execution period.

0
MaxWaitTimedouble

Max wait time (in milliseconds) during the execution period.

3.4
MaxApplicationWaitTimedouble

Max Application event wait time (in milliseconds) during the execution period

0
MaxConcurrencyWaitTimedouble

Max Concurrency event wait time (in milliseconds) during the execution period

0
MaxUserIoWaitTimedouble

Max UserIO event wait time (in milliseconds) during the execution period

0
MaxDiskReadsdouble

Max physical read count during the execution period.

0
AvgExpectedWorkerCountdouble

Average degree of parallelism during the execution period.

3
AvgUsedWorkerCountdouble

Average number of threads used of the SQL during the execution period.

3
SumLogicalReadsdouble

Total logical reads.

0
ExecPsdouble

Average execution count per second during the execution period.

0.31

Examples

Sample success responses

JSONformat

{
  "RequestId": "EE205C00-30E4-****-****-87E3A8A2AA0C",
  "Data": [
    {
      "SQLId": "8D6E84****0B8FB1823D199E2CA1****",
      "DbName": "test_db",
      "AvgAffectedRows": 9978.75,
      "AvgBlockCacheHit": 0,
      "AvgBlockIndexCacheHit": 0,
      "AvgBloomFilterCacheHit": 0,
      "Executions": 1,
      "FailCount": 0,
      "AvgRpcCount": 8,
      "RemotePlans": 0,
      "MissPlans": 0,
      "AvgReturnRows": 0,
      "AvgLogicalReads": 0,
      "RetryCount": 0,
      "AvgRowCacheHit": 0,
      "AvgDiskReads": 0,
      "AvgMemstoreReadRows": 0,
      "AvgSsstoreReadRows": 0,
      "AvgApplicationWaitTime": 0,
      "AvgElapsedTime": 1876.78,
      "AvgExecuteTime": 1895.7,
      "AvgQueueTime": 0.01,
      "AvgConcurrencyWaitTime": 0,
      "AvgCpuTime": 1875.34,
      "AvgDecodeTime": 0,
      "AvgNetWaitTime": 0,
      "AvgUserIoWaitTime": 0,
      "AvgGetPlanTime": 0,
      "MaxElapsedTime": 13643.3,
      "SumWaitTime": 9421.73,
      "AvgScheduleTime": 0,
      "MaxCpuTime": 13641.9,
      "SumElapsedTime": 11452126.36,
      "Timestamp": "2023-04-12T04:46:38Z",
      "Server": "i-bp1db1****8uemejio",
      "UserName": "test_user",
      "AvgPartitionCount": 1,
      "FailPercentage": 0,
      "RetCode4012Count": 0,
      "RetCode4013Count": 0,
      "RetCode5001Count": 0,
      "RetCode5024Count": 0,
      "RetCode5167Count": 0,
      "RetCode5217Count": 0,
      "RetCode6002Count": 0,
      "AvgWaitTime": 1442.49,
      "AvgWaitCount": 0,
      "LocalPlanPercentage": 0,
      "RemotePlanPercentage": 0,
      "DistPlanPercentage": 100,
      "AvgNetTime": 8,
      "AvgExecutorRpcCount": 0,
      "MissPlanPercentage": 0,
      "TableScanPercentage": 0,
      "StrongConsistencyPercentage": 100,
      "WeakConsistencyPercentage": 0,
      "MaxAffectedRows": 10000,
      "MaxReturnRows": 0,
      "MaxWaitTime": 3.4,
      "MaxApplicationWaitTime": 0,
      "MaxConcurrencyWaitTime": 0,
      "MaxUserIoWaitTime": 0,
      "MaxDiskReads": 0,
      "AvgExpectedWorkerCount": 3,
      "AvgUsedWorkerCount": 3,
      "SumLogicalReads": 0,
      "ExecPs": 0.31
    }
  ]
}

Error codes

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

Change history

Change timeSummary of changesOperation
2024-02-02The response structure of the API has changedsee changesets
Change itemChange content
Output ParametersThe response structure of the API has changed.
2023-08-21The request parameters of the API has changedsee changesets
Change itemChange content
Input ParametersThe request parameters of the API has changed.
    Added Input Parameters: DynamicSql