All Products
Search
Document Center

Data Transmission Service:DescribeDataCheckTableDetails

更新時間:Apr 07, 2024

Queries the information about a full or incremental data verification task.

Debugging

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 DescribeDataCheckTableDetails

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

Status String No -1

The status of data verification results. Valid values:

  • -1 (default): all states.
  • 6: inconsistent data detected in tables.
PageSize Integer No 10

The number of entries per page.

PageNumber Integer No 1

The page number. Pages start from page 1. Default value: 1.

CheckType Integer Yes 1

The data verification method. Valid values:

  • 1: full data verification.
  • 2: incremental data verification.
TableName String No student

The name of the table whose data is verified in the source database.

DtsJobId String Yes xd4e4xb419q****

The ID of the data migration or data synchronization task. You can call the DescribeDtsJobs operation to query the task ID.

SchemaName String No dtstest

The schema name of the verification object in the source database.

Response parameters

Parameter

Type

Example

Description

HttpStatusCode Integer 200

The returned HTTP status code.

RequestId String 621BB4F8-3016-4FAA-8D5A-5D3163CC****

The request ID.

ErrCode String InternalError

The error code returned if the request failed.

Success Boolean true

Indicates whether the request was successful.

ErrMessage String The Value of Input Parameter %s is not valid.

The error message returned if the request failed.

DynamicMessage String Type

The dynamic part in the error message. This parameter is used to replace the **%s** variable of ErrMessage.

Note

For example, if the return value of ErrMessage is The Value of Input Parameter %s is not valid and the return value of DynamicMessage is Type, the specified value of Type is invalid.

PageNumber Integer 2

The page number.

DynamicCode String 403

The dynamic error code. This parameter is going to be removed in the future.

TableDetails Array of TableDetails

The details of data verification results.

Status String 0

The state of the data verification task. Valid values:

  • 0: The data verification task was complete.
  • 2: The data verification task was being initialized.
  • 3: The data verification task was in progress.
  • 5: The data verification task failed.
Id Long 167401241974****

The auto-increment primary key that is used to identify the data in a verification result.

SourceDbName String testdb

The name of the source database.

TargetDbName String testdb

The name of the destination database.

SourceTbName String student

The name of the source table.

TargetTbName String person

The name of the destination table.

TotalCount Long 8

The total number of data rows.

FinishCount Long 7

The number of data rows that were verified.

DiffCount Long 1

The number of data rows that contain inconsistent data.

BootTime String 2023-01-18 11:26:59

The time when data verification was performed.

ErrorCode Integer 1

The error code returned if the data verification task failed. Valid values:

  • 1: The number of tables that do not contain primary keys exceeds the limit.
  • 2: The number of data rows that contain inconsistent data exceeds 300.
  • 3: One or more tables to be verified do not exist.
  • 4: The SQL statements used for verifying data contain a syntax error.
TotalCount Long 1

The total number of tables on which data verification was performed.

FinishedCount Long 7

The total number of data rows that were verified.

DiffTableCount Long 1

The number of tables that contain inconsistent data.

Examples

Sample requests

http(s)://dts.aliyuncs.com/?Action=DescribeDataCheckTableDetails
&CheckType=2
&DtsJobId=xd4e4xb419q****
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<DescribeDataCheckTableDetailsResponse>
    <DiffTableCount>1</DiffTableCount>
    <TableDetails>
        <Status>0</Status>
        <SourceTbName>student</SourceTbName>
        <TotalCount>8</TotalCount>
        <TargetTbName>person</TargetTbName>
        <TargetDbName>testdb</TargetDbName>
        <FinishCount>7</FinishCount>
        <BootTime>2023-04-23 18:35:05</BootTime>
        <Id>1682246105030001</Id>
        <SourceDbName>testdb</SourceDbName>
        <DiffCount>1</DiffCount>
    </TableDetails>
    <TotalCount>1</TotalCount>
    <RequestId>B8BCB980-CDC2-5628-A6F0-AB1910AA****</RequestId>
    <PageNumber>1</PageNumber>
    <FinishedCount>7</FinishedCount>
    <HttpStatusCode>200</HttpStatusCode>
    <Success>true</Success>
</DescribeDataCheckTableDetailsResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "DiffTableCount" : 1,
  "TableDetails" : [ {
    "Status" : 0,
    "SourceTbName" : "student",
    "TotalCount" : 8,
    "TargetTbName" : "person",
    "TargetDbName" : "testdb",
    "FinishCount" : 7,
    "BootTime" : "2023-04-23 18:35:05",
    "Id" : 1682246105030001,
    "SourceDbName" : "testdb",
    "DiffCount" : 1
  } ],
  "TotalCount" : 1,
  "RequestId" : "B8BCB980-CDC2-5628-A6F0-AB1910AA****",
  "PageNumber" : 1,
  "FinishedCount" : 7,
  "HttpStatusCode" : 200,
  "Success" : true
}

Error codes

HTTP status code

Error code

Error message

Description

400 Throttling.User Request was denied due to user flow control. The number of requests exceeded the limit, and the request was rejected. Try again later.
500 ServiceUnavailable The request has failed due to a temporary failure of the server. The response of the server timed out or the server was unavailable. Try again. If the error persists, contact technical support.
403 InvalidSecurityToken.Expired Specified SecurityToken is expired. The signature expired. Use a new signature.

For a list of error codes, see Service error codes.