Creating a Task for Parsing All SQL Statements of Multiple Days
Function
This API is used to create a task for parsing all SQL statements of multiple days.
Authorization Information
Each account has permissions to call all APIs, but IAM users must have the required permissions specifically assigned.
- If you are using role/policy-based authorization, see the required permissions in Permissions Policies and Supported Actions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
Action
Access Level
Resource Type (*: required)
Condition Key
Alias
Dependencies
das:clouddba:fullSqlList
Write
Instance
-
-
-
URI
POST /v3/{project_id}/fullsql/task/add-tasks
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition Project ID of a tenant in a region. To obtain this value, see Obtaining a Project ID. Constraints N/A Range The value can contain 32 characters. Only letters and digits are supported. Default Value N/A |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| instance_id | Yes | String | Definition Unique ID of an instance Constraints N/A Range The value can contain 32 characters. Only letters and digits are supported. Default Value N/A |
| start_at | Yes | Long | Definition Start time in the Unix timestamp format, in milliseconds Constraints N/A Range [0, 2^31 – 1]. The actual value depends on the query result. Default Value N/A |
| end_at | Yes | Long | Definition End time in the Unix timestamp format, in milliseconds Constraints N/A Range [0, 2^31 – 1]. The actual value depends on the query result. Default Value N/A |
| node_id | No | String | Definition Node ID Constraints N/A Range The value can contain 32 characters. Only letters and digits are supported. Default Value N/A |
| keyword | No | String | Definition Keyword Constraints Multiple values need to be separated by commas (,). Range N/A Default Value N/A |
| user_list | No | String | Definition Username Constraints Multiple values need to be separated by commas (,). Range N/A Default Value N/A |
| db_list | No | String | Definition Database Constraints Multiple values need to be separated by commas (,). Range N/A Default Value N/A |
| operation_list | No | String | Definition Operation type Constraints Multiple values need to be separated by commas (,). Range N/A Default Value N/A |
| thread_id_list | No | String | Definition Thread ID Constraints Multiple values need to be separated by commas (,). Range N/A Default Value N/A |
| trx_id_list | No | String | Definition Transaction ID Constraints Multiple values need to be separated by commas (,). Range N/A Default Value N/A |
| status_list | No | String | Definition Execution status Constraints Multiple values need to be separated by commas (,). Range
Default Value N/A |
| sql_template_ids | No | String | Definition SQL template ID Constraints Multiple values need to be separated by commas (,). Range N/A Default Value N/A |
Response Parameters
Status code: 200
Example Requests
POST https://das.cn-north-1.myhuaweicloud.com/v3/054e292c9880d4992f02c0196d3ea468/fullsql/task/add-tasks
{
"instance_id": "bcfa975193f1402fa11a6d4fd6baf5fbin01",
"node_id": "",
"start_at": 1763713601000,
"end_at": 1763713931000,
"user_list": "",
"keyword": "",
"db_list": "",
"operation_list": "",
"thread_id_list": "",
"trx_id_list": "",
"status_list": ""
} Example Responses
Status code: 200
Success.
Status Codes
| Status Code | Description |
|---|---|
| 200 | Success. |
| 400 | Client error. |
| 500 | Server error. |
Error Codes
See Error Codes.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot