Executing a SQL Diagnosis
Function
This API is used to execute a SQL diagnosis.
URI
POST /v3/{project_id}/connections/{connection_id}/tuning/create-tuning
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
project_id |
Yes |
String |
Project ID. To obtain this value, see Obtaining a Project ID. |
connection_id |
Yes |
String |
Connection ID. |
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
X-Auth-Token |
Yes |
String |
User token. |
X-Language |
No |
String |
Language. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
database_name |
Yes |
String |
Database name. |
schema_name |
No |
String |
Schema name. |
sql_script |
Yes |
String |
SQL script. |
node_type |
No |
String |
Node type. |
node_id |
No |
String |
Node ID. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
message_id |
Array of strings |
Diagnosis information ID. |
status |
Boolean |
Status. |
quota_exceeded |
Boolean |
Diagnosis quota status. |
Status code: 400
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code. Minimum length: 8 Maximum length: 36 |
error_msg |
String |
Error message. Minimum length: 2 Maximum length: 512 |
Status code: 500
Parameter |
Type |
Description |
---|---|---|
error_code |
String |
Error code. Minimum length: 8 Maximum length: 36 |
error_msg |
String |
Error message. Minimum length: 2 Maximum length: 512 |
Example Requests
Executing a SQL diagnosis
POST https://{{endpoint}}/v3/{{project_id}}/connections/{connection_id}/tuning/create-tuning { "database_name" : "string", "schema_name" : "string", "sql_script" : "string" }
Example Responses
{ "message_id": [ "6507f5070cf2476b18473d9b" ], "status": true, "quota_exceeded": false }
Status Code
Status Code |
Description |
---|---|
200 |
Success. |
400 |
Bad request. |
500 |
Internal server error. |
Error Code
See Error Codes.
Feedback
Was this page helpful?
Provide feedbackThank 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