Mengkueri informasi eksekusi tentang Pernyataan SQL, termasuk rencana eksekusi, informasi eksekusi, Penggunaan sumber daya, dan hasil diagnostik mandiri.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
adb:DescribeDiagnosisSQLInfo |
get |
DBCluster
|
None | None |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| DBClusterId |
string |
Yes |
ID kluster. Catatan
Anda dapat memanggil operasi DescribeDBClusters untuk mengkueri ID kluster semua kluster Database Analitik for MySQL Edisi Gudang Data di wilayah tertentu. |
am-bp1r053byu48p**** |
| RegionId |
string |
Yes |
ID wilayah kluster. Catatan
Anda dapat memanggil operasi DescribeRegions untuk mengkueri daftar wilayah terbaru. |
cn-hangzhou |
| ProcessId |
string |
Yes |
ID kueri. Catatan
Anda dapat memanggil operasi DescribeDiagnosisRecords untuk mengkueri informasi ringkasan SQL dari Kluster Database Analitik for MySQL tertentu, termasuk ID kueri. |
2021070216432217201616806503453****** |
| ProcessStartTime |
integer |
No |
Waktu mulai eksekusi Pernyataan SQL. Tentukan waktu dalam format Stempel waktu UNIX. Unit: milidetik. Catatan
Anda dapat memanggil operasi DescribeDiagnosisRecords untuk mengkueri informasi ringkasan SQL dari Kluster Database Analitik for MySQL tertentu, termasuk Waktu mulai eksekusi Pernyataan SQL. |
1625215402000 |
| ProcessState |
string |
No |
Status Pernyataan SQL. Nilai valid:
Catatan
Anda dapat memanggil operasi DescribeDiagnosisRecords untuk mengkueri informasi ringkasan SQL dari Kluster Database Analitik for MySQL tertentu, termasuk Status Pernyataan SQL. |
running |
| Lang |
string |
Yes |
Bahasa judul file dan pesan error. Nilai valid:
|
zh |
| ProcessRcHost |
string |
No |
Alamat IP dan nomor Port node frontend Database Analitik for MySQL tempat Pernyataan SQL dieksekusi. Catatan
Anda dapat memanggil operasi DescribeDiagnosisRecords untuk mengkueri informasi ringkasan SQL dari Kluster Database Analitik for MySQL tertentu, termasuk alamat IP dan nomor Port node frontend. |
192.45.***.***:3145 |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
|||
| DiagnosisSQLInfo |
string |
Execution details of the SQL statement, including the SQL statement text, statistics, execution plan, and operator information. |
{ "DiagnosisSQLInfo": { "hasSharedStage": false, "resourceGroup": "user_default", "cost": 274, "queuedTime": 0, "outputDataSize": 9, "scheduled": true, "query": "/*+display=tpch_q14*/SELECT 100.00 * SUM(CASE WHEN p_type LIKE 'PROMO%' THEN l_extendedprice * (1 - l_discount) ELSE 0 END) / SUM(l_extendedprice * (1 - l_discount)) AS promo_revenue FROM lineitem l, part p WHERE l_partkey = p_partkey AND l_shipdate >= DATE '1995-09-01' AND l_shipdate < DATE '1995-09-01' + INTERVAL '1' MONTH", "outputRows": 1, "userName": "test_user", "parentId": 0, "maxOutputRows": 200000, "scanSize": 8247470, "peakMemory": 13188295, "startTime": 1626330527632, "state": "FINISHED", "endTime": 1626330527905, "writeTableRows": 0, "scanRows": 351966 } } |
| RequestId |
string |
The ID of the request. |
1 |
| StageInfos |
array<object> |
Execution details of the query by stage. |
|
|
object |
|||
| InputRows |
integer |
The total number of input rows in the stage. |
123 |
| InputDataSize |
integer |
The total amount of input data in the stage. Unit: bytes. |
2341 |
| OutputRows |
integer |
The total number of output rows in the stage. |
231 |
| OutputDataSize |
integer |
The total amount of output data in the stage. Unit: bytes. |
12344 |
| PeakMemory |
integer |
The total peak memory of the stage. Unit: bytes. |
3421 |
| OperatorCost |
integer |
The total amount of time consumed by all operators in the stage. Unit: milliseconds. |
2341 |
| StageId |
string |
The ID of the stage. |
Stage[26] |
| State |
string |
The state of the stage. Valid values:
|
RUNNING |
| Progress |
number |
The execution progress of the stage. |
0.3 |
Contoh
Respons sukses
JSONformat
{
"DiagnosisSQLInfo": "{ \"DiagnosisSQLInfo\": { \"hasSharedStage\": false, \"resourceGroup\": \"user_default\", \"cost\": 274, \"queuedTime\": 0, \"outputDataSize\": 9, \"scheduled\": true, \"query\": \"/*+display=tpch_q14*/SELECT 100.00 * SUM(CASE WHEN p_type LIKE 'PROMO%' THEN l_extendedprice * (1 - l_discount) ELSE 0 END) / SUM(l_extendedprice * (1 - l_discount)) AS promo_revenue FROM lineitem l, part p WHERE l_partkey = p_partkey AND l_shipdate >= DATE '1995-09-01' AND l_shipdate < DATE '1995-09-01' + INTERVAL '1' MONTH\", \"outputRows\": 1, \"userName\": \"test_user\", \"parentId\": 0, \"maxOutputRows\": 200000, \"scanSize\": 8247470, \"peakMemory\": 13188295, \"startTime\": 1626330527632, \"state\": \"FINISHED\", \"endTime\": 1626330527905, \"writeTableRows\": 0, \"scanRows\": 351966 } }",
"RequestId": "1",
"StageInfos": [
{
"InputRows": 123,
"InputDataSize": 2341,
"OutputRows": 231,
"OutputDataSize": 12344,
"PeakMemory": 3421,
"OperatorCost": 2341,
"StageId": "Stage[26]",
"State": "RUNNING",
"Progress": 0.3
}
]
}
Kode kesalahan
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.