Skip to main content

Required settings

  • Host name
  • Port (default is 1433)
  • Service account
  • Database name
  • CDC enabled for database and tables to replicate
In order to enable CDC for SQL Server, you will enable it at the database and table level.
  1. Enable CDC for your database
  1. Enable CDC for your tables

Troubleshooting

When you alter the table’s schema, you will need to rotate the capture instances so that changes continue to be captured.
By default, sys.sp_cdc_enable_table will use the primary keys of the table as the unique identifiers. If you are running into issues with this, you can optionally set @index_name to an unique index of your choice.For example, if you had a table that looked like this
If you don’t want to use id, you can do something like this: