- Newest
- Most votes
- Most comments
The issue you're experiencing with duplicated PK entries in the ExportTableToPointInTime output to S3 is not a known limitation or common problem with the API. However, there are a few points to consider and steps you can take to investigate and potentially resolve this issue:
-
Consistency: While the ExportTableToPointInTime operation provides a consistent snapshot of the table at a specific point in time, it's important to note that the exported data is eventually consistent, not transactionally consistent. This means that there might be some discrepancies between the actual table state and the exported data.
-
PITR window: Ensure that the export time you're specifying is within the valid Point-in-Time Recovery (PITR) window. If the specified time is outside this window, it could potentially lead to unexpected results.
-
Export format: You're using the DYNAMODB_JSON format, which is correct. However, you might want to try exporting in ION format as an alternative to see if the issue persists.
-
Incremental export: If this is a recurring issue, you might want to consider using incremental exports instead of full exports. This allows you to export only the data that has changed within a specific time period, which might help isolate the problem.
-
Verify export completion: Make sure that the export operation has completed successfully. You can check the status of the export using the DescribeExport API or by monitoring the export task in the AWS Management Console.
-
S3 integrity: Verify the integrity of the S3 objects after the export. Ensure that there were no issues during the data transfer to S3.
-
AWS Support: If the issue persists after trying these steps, it would be advisable to contact AWS Support. They can provide more detailed investigation and potentially identify any underlying issues with the export process.
To ensure the export doesn't produce duplicate data, you can:
- Double-check the table's PITR settings and ensure they're correctly configured.
- Use a more recent point in time for the export, if possible.
- Consider using DynamoDB Streams or Kinesis Data Streams for DynamoDB in conjunction with the export to capture any changes that occur during the export process.
Remember, if you need to keep the source and target tables in sync after the export, you can use DynamoDB Streams with AWS Lambda to replay any writes that occurred in the source table since the export started.
Sources
ExportTableToPointInTime - Amazon DynamoDB
Migrate a table using export to S3 and import from S3 - Amazon DynamoDB
Requesting a table export in DynamoDB - Amazon DynamoDB
answered 2 years ago
Relevant content
- AWS OFFICIALUpdated 3 years ago
- AWS OFFICIALUpdated 4 years ago

What do you mean by duplicated across all its SKs? Each line in file should have a unique item (PK + SK). You can have many items related to the same PK, which is known as an item collection.