Skip to main content

Query Schema Comparison Main Task Details

Query basic information and the latest execution information for a specified schema comparison main task.

Request URL: /openapi/v1/compareschema/queryTaskById

Request Method: GET

Before You Call

taskId can be obtained from data.taskId in the successful response of Create Schema Comparison Task, or from data.schemaComparisons[].taskId returned by List Schema Comparison Tasks.

Request Parameters

ParameterTypeRequiredDescriptionExample
taskIdStringYesSchema comparison main task ID.cc-th6j3fs58y

How to Use the Returned Value

data.lastExecId in the response is the latest schema comparison subtask ID. Use it when calling Query Schema Comparison Subtask Details, Query Schema Comparison Object Results, and Query Schema Comparison Correction SQL.

Response Parameters

ParameterTypeDescriptionExample
successBooleanWhether the request is successful.true
requestIdStringRequest ID, which can be used for troubleshooting and tracing.Jf5c0IKB-bhicqBRndhhr5TEdchr4BRP
dataObjectSchema comparison main task details. See the fields below.See the example below
messageStringError message returned when the request fails.task not found

data Fields

ParameterTypeDescriptionExample
taskIdStringSchema comparison main task ID.cc-th6j3fs58y
lastExecIdLongLatest schema comparison subtask ID.46958
statusStringTask status. Common values include success, failed, starting, and running.starting
nameStringTask name.schema_compare_demo
isDeletedBooleanWhether the task is deleted.false
errMsgStringError message returned when the task fails or is abnormal.""

Request Example

{
"taskId": "cc-th6j3fs58y"
}

Successful Invocation Example

{
"success": true,
"requestId": "Jf5c0IKB-bhicqBRndhhr5TEdchr4BRP",
"data": {
"taskId": "cc-th6j3fs58y",
"lastExecId": 46958,
"status": "starting",
"name": "schema_compare_demo",
"isDeleted": false
}
}