Select Language:
When using AWS Database Migration Service (DMS) for change data capture (CDC), you might notice that new columns added to your source table don’t show up in your replicated data. This usually happens because schema changes aren’t automatically handled. Here’s how you can fix this issue and make sure your replication stays up-to-date with any changes to your table structure.
The key is to enable how AWS DMS handles schema changes, especially ALTER TABLE commands that add new columns. To do this, you’ll need to adjust your migration task settings. First, stop your current DMS replication task. Then, go into the task settings and find the JSON editor. Look for the section called “ChangeProcessingDdlHandlingPolicy.” Inside this section, find the setting called “HandleSourceTableAltered” and set it to true. This setting allows DMS to automatically capture schema changes like new columns.
Once you’ve made this change, restart your replication task. However, keep in mind that simply turning on schema change handling won’t automatically add new columns to your existing data stream. You’ll also need to reload the affected table so that the new columns are included in your data output. This step ensures that your data stream matches the latest table structure.
For best results, it’s a good idea to set “HandleSourceTableAltered” to true before you start your CDC replication. Doing so ensures that your migration process will automatically catch any future schema changes without extra steps. If you’ve already begun your replication without this setting, you’ll need to stop the task, update the schema handling policy as described, restart the task, and then reload your table to include any new columns.
This process works across various DMS setups, including serverless configurations. The good news is, you won’t need to recreate your entire migration setup—just update the settings and reload the table. With these steps, your data will always stay in sync with the source, even when your schema changes.





