Menu
AWS Database Migration Service
API Reference (API Version 2016-01-01)

DescribeTableStatistics

Returns table statistics on the database migration task, including table name, rows inserted, rows updated, and rows deleted.

Note that the "last updated" column the DMS console only indicates the time that AWS DMS last updated the table statistics record for a table. It does not indicate the time of the last update to the table.

Request Syntax

{
   "Filters": [ 
      { 
         "Name": "string",
         "Values": [ "string" ]
      }
   ],
   "Marker": "string",
   "MaxRecords": number,
   "ReplicationTaskArn": "string"
}

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

Filters

Filters applied to the describe table statistics action.

Valid filter names: schema-name | table-name | table-state

A combination of filters creates an AND condition where each record matches all specified filters.

Type: Array of Filter objects

Required: No

Marker

An optional pagination token provided by a previous request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.

Type: String

Required: No

MaxRecords

The maximum number of records to include in the response. If more records exist than the specified MaxRecords value, a pagination token called a marker is included in the response so that the remaining results can be retrieved.

Default: 100

Constraints: Minimum 20, maximum 500.

Type: Integer

Required: No

ReplicationTaskArn

The Amazon Resource Name (ARN) of the replication task.

Type: String

Required: Yes

Response Syntax

{
   "Marker": "string",
   "ReplicationTaskArn": "string",
   "TableStatistics": [ 
      { 
         "Ddls": number,
         "Deletes": number,
         "FullLoadCondtnlChkFailedRows": number,
         "FullLoadErrorRows": number,
         "FullLoadRows": number,
         "Inserts": number,
         "LastUpdateTime": number,
         "SchemaName": "string",
         "TableName": "string",
         "TableState": "string",
         "Updates": number,
         "ValidationFailedRecords": number,
         "ValidationPendingRecords": number,
         "ValidationState": "string",
         "ValidationSuspendedRecords": number
      }
   ]
}

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

Marker

An optional pagination token provided by a previous request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.

Type: String

ReplicationTaskArn

The Amazon Resource Name (ARN) of the replication task.

Type: String

TableStatistics

The table statistics.

Type: Array of TableStatistics objects

Errors

For information about the errors that are common to all actions, see Common Errors.

InvalidResourceStateFault

The resource is in a state that prevents it from being used for database migration.

HTTP Status Code: 400

ResourceNotFoundFault

The resource could not be found.

HTTP Status Code: 400

Example

Sample Request

   
POST / HTTP/1.1
Host: dms.<region>.<domain>
x-amz-Date: <Date>
Authorization: AWS4-HMAC-SHA256 
Credential=<Credential>, 
SignedHeaders=contenttype;date;host;user-
agent;x-amz-date;x-amz-target;x-amzn-
requestid,Signature=<Signature>
User-Agent: <UserAgentString>
Content-Type: application/x-amz-json-1.1
Content-Length: <PayloadSizeBytes>
Connection: Keep-Alive
X-Amz-Target: AmazonDMSv20160101.DescribeTableStatistics
{
     "ReplicationTaskArn": "arn:aws:dms:us-west-
     2:918017823489:task:WZVIPF3D4AJSNJASB42D4Z7GBE",
     "SchemaName": "",
     "TableNames": [
          ""
          ],
     "MaxRecords": 0,
     "Marker": ""
}
 

Sample Response


 HTTP/1.1 200 OK
x-amzn-RequestId: <RequestId>
Content-Type: application/x-amz-json-1.1
Content-Length: <PayloadSizeBytes>
Date: <Date>
{
"ReplicationTaskArn": "arn:aws:dms:us-west-
2:918017823489:task:WZVIPF3D4AJSNJASB42D4Z7GBE",
"TableStatistics": [
{
     "Inserts": 3872,
     "LastUpdateTime": 1457655132.796,
     "Ddls": 1,
     "TableName": "DataInsert_5D28A14AB66AB4ED",
     "Updates": 0,
     "FullLoadRows": 0,
     "TableState": "Table completed",
     "SchemaName": "rdststdb",
     "Deletes": 0
},
{
     "Inserts": 0,
     "LastUpdateTime": 1457655132.796,
     "Ddls": 0,
     "TableName": "DataInsert_05CF105ABC22BB83",
     "Updates": 0,
     "FullLoadRows": 0,
     "TableState": "Table completed",
     "SchemaName": "rdststdb",
     "Deletes": 0
},
{
     "Inserts": 0,
     "LastUpdateTime": 1457655132.796,
     "Ddls": 0,
     "TableName": "DataInsert_BEB962DE10FB7B60",
     "Updates": 0,
     "FullLoadRows": 0,
     "TableState": "Table completed",
     "SchemaName": "rdststdb",
     "Deletes": 0
     }
     ]
}    
 

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: