Queries the precheck information about an SQL statement that is specified in a data change ticket.

For more information about the Normal Data Modify feature, see Change regular data.


OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes ListDataCorrectPreCheckSQL

The operation that you want to perform. Set the value to ListDataCorrectPreCheckSQL.

OrderId Long Yes 453****

The ID of the data change ticket. You can call the ListOrders operation to query the ID of the data change ticket.

PageNumber Long No 1

The number of the page to return.

PageSize Long No 10

The number of entries to return on each page.

DbId Long No 1930****

The ID of the database. The database can be a physical database or a logical database.

Tid Long No 3***

The ID of the tenant. You can call the GetUserActiveTenant operation to query the tenant ID.

RegionId String No cn-hangzhou

The ID of the region in which Data Management (DMS) is activated. Set this parameter to the ID of the region that is in proximity to your applications. For more information about the valid values of this parameter, see RegionID parameter.

Response parameters

Parameter Type Example Description
RequestId String 31853A2B-DC9D-5B39-8492-D2AC8BCF550E

The ID of the request.

Success Boolean true

Indicates whether the request is successful. Valid values:

  • true: The request is successful.
  • false: The request fails.
ErrorMessage String UnknownError

The error message returned.

ErrorCode String UnknownError

The error code returned.

PreCheckSQLList Array of PreCheckSQL

The precheck information about SQL statements.

CheckSQL String CheckSQL": "OPTIMIZE TABLE `Text_TableNames`

The SQL statement.

AffectRows Long 0

The estimated number of affected rows.

DbId Long 1930****

The ID of the database.

SQLReviewQueryKey String b9e771fc6ec247dea6d06a32c777****

The key that is used to query the details of optimization suggestions. You can call the GetSQLReviewOptimizeDetail operation to query the details of optimization suggestions based on the key.

SqlReviewStatus String WAITING

The review status of the SQL statement. Valid values:

  • WAITING: The SQL statement is pending for review.
  • RUNNING: The SQL statement is being reviewed.
  • IGNORE: The SQL statement review is skipped.
  • PASS: The SQL statement passed the review.
  • BLOCK: The SQL statement failed the review.
SqlType String OPTIMIZE

The type of the SQL statement, such as DELETE, UPDATE, or ALTER_TABLE.

TableNames String Text_TableNames

The name of the table whose data is changed.


Sample requests

&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK

        <CheckSQL>OPTIMIZE TABLE `Text_TableNames`</CheckSQL>

JSON format

HTTP/1.1 200 OK

  "RequestId" : "31853A2B-DC9D-5B39-8492-D2AC8BCF550E",
  "PreCheckSQLList" : [ {
    "CheckSQL" : "OPTIMIZE TABLE `Text_TableNames`",
    "SqlReviewStatus" : "WAITING",
    "TableNames" : "`Text_TableNames`,",
    "DbId" : "1930****",
    "SqlType" : "OPTIMIZE",
    "AffectRows" : 0
  } ],
  "Success" : true

Error codes

For a list of error codes, visit the API Error Center.