Quantcast
Channel: Active questions tagged change-data-capture - Database Administrators Stack Exchange
Viewing all articles
Browse latest Browse all 132

CDC capture Job Step-2 is not running when enabling CDC on table in SQL Server and Change table is empty

$
0
0

My Database has CDC enabled and the table i want to track changes using the below T-SQL,

EXEC sys.sp_cdc_enable_db;GO    EXEC sys.sp_cdc_enable_table@source_schema = N'dbo',@source_name   = N'tblName',@role_name     = NULL,@supports_net_changes = 1;GO

Then two jobs created for cdc capture and cleanup.

1. cdc.DBName_capture2. cdc.DBName_cleanup

Capture job having the two steps to execute

1. Starting Change Data Capture Collection Agent  2. Change Data Capture Collection Agent. 

But, when I view the history (With right clicking the capture job and click 'View history'), and found that Step 1 is executed, and there is no step 2.

Also, there is no data recorded in tblName_CT table while inserting or updating the table.

Note: Also, cdc.lsn_time_mapping table doesn't have any entries. SQL Server Agent is runnning, and I also tried the whole steps after restarting the SQL Server Agent. But, no change data captured in tableName_CT table.

How to resolve and capture the changes?

Thank you so much, in advance!


Viewing all articles
Browse latest Browse all 132

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>