change-data-capture

SQL Server Change Data Capture - Capture user who made the change

六月ゝ 毕业季﹏ 提交于 2020-07-21 04:15:09
问题 Concerning SQL Server Change Data Capture , can you track the User who has made the change to the row/column data or is there anyway to extend CDC to allow this? I couldn't see anything in the documentation. 回答1: You can't capture username with CDC.. You have to use Auditing to do so or if this is a one time request,you can query TLOG.. Below is the connect item requesting the same.. CDC : options to capture more data (username, date/time, etc) You also can use triggers as per this article

Change Data Capture For Updates and Deletes Only

旧街凉风 提交于 2020-06-27 12:06:17
问题 Our database is insert inensive (200-500k per night) but update light (maybe a few hundred per day). I need to preserve a history of all changes to the inserted rows themselves for an indefinite period of time (but not the actual insert). I would love to use Change Data Capture but the amount of space required to support this is not avaiable. If I can figure out of to do one of the following, my life would be much easier. 1) Limite change data tracking to UPDATES and DELETES only 2) Cleanup

How to integrate Oracle and Kafka

半腔热情 提交于 2020-06-19 19:03:21
问题 I've been trying to find the most efficient/effective way capture change notifications in a single Oracle 11g R2 instance and deliver those events to an Apache Kafka queue, but I haven't been able to find any simple examples or tutorials along these lines. I've seen some possibilities on the Oracle side (Streams, Change Data Capture,triggers (yuck), etc..), but I'm still not sure which would be best to pursue. Here is a project utilizing MySQL and Kafka on GitHub called mypipe, I just haven't

How to integrate Oracle and Kafka

安稳与你 提交于 2020-06-19 19:02:17
问题 I've been trying to find the most efficient/effective way capture change notifications in a single Oracle 11g R2 instance and deliver those events to an Apache Kafka queue, but I haven't been able to find any simple examples or tutorials along these lines. I've seen some possibilities on the Oracle side (Streams, Change Data Capture,triggers (yuck), etc..), but I'm still not sure which would be best to pursue. Here is a project utilizing MySQL and Kafka on GitHub called mypipe, I just haven't

Difference between MIN(__$start_lsn) and fn_cdc_get_min_lsn?

自闭症网瘾萝莉.ら 提交于 2020-01-07 04:44:39
问题 Using CDC on SQL Server 2012. I have a table ( MyTable ) which is CDC enabled. I thought the following two queries would always return the same value: SELECT MIN(__$start_lsn) FROM cdc.dbo_MyTable_CT; SELECT sys.fn_cdc_get_min_lsn('dbo_MyTable'); But they don't seem to do so: in my case the first one returns 0x00001EC6000000DC0003 and the second one 0x00001E31000000750001 , so the absolute minimum in the table is actually greater than the value returned by fn_cdc_get_min_lsn . My questions:

How to remove columns from CDC (in SQL Server)

大憨熊 提交于 2020-01-06 19:31:18
问题 I've enabled CDC on a table, using the code below, and by default it includes all of the columns. There is another way to enable CDC on a table while SPECIFYING the columns (code is given below). However, for me, that's too late - given my CDC was already created and includes ALL of the columns. How do I remove the columns I don't want from the CDC watch list (I searched everywhere in the meta data and couldn't find anything): -- The following enabled the CDC on a table: EXECUTE sys.sp_cdc

SQL CDC data processing options

╄→尐↘猪︶ㄣ 提交于 2020-01-03 05:33:12
问题 I have a SQL Server CDC set up on few tables. Once the CDC is intiated the cdc tables are populated. I would want to process these changes and generate MQ messages for every change that occurs to send it to an external message queue. What is the best way to process this data. I have looked at few products like sqdata but I was thinking if there is any better way of doing it. I have looked at CDC with Service broker but this generates message to be send to an external application only. My

CDC is enabled, but cdc.dbo<table-name>_CT table is not being populated

送分小仙女□ 提交于 2020-01-01 12:17:30
问题 I have enabled CDC using the following steps: exec sys.sp_cdc_enable_db; exec sys.sp_cdc_enable_table @source_schema = N'dbo', @source_name = N'table_name', @role_name = N'CDC_Access', @supports_net_changes = 1; I can see that a CT table has been created in the System Tables ; SQL Server Agent is on, and I can see the cdc.db_name_capture job has been created and is running. However, even though the table_name table is being populated, I never see anything in the CT table. I have other tables

CDC is enabled, but cdc.dbo<table-name>_CT table is not being populated

给你一囗甜甜゛ 提交于 2020-01-01 12:17:10
问题 I have enabled CDC using the following steps: exec sys.sp_cdc_enable_db; exec sys.sp_cdc_enable_table @source_schema = N'dbo', @source_name = N'table_name', @role_name = N'CDC_Access', @supports_net_changes = 1; I can see that a CT table has been created in the System Tables ; SQL Server Agent is on, and I can see the cdc.db_name_capture job has been created and is running. However, even though the table_name table is being populated, I never see anything in the CT table. I have other tables

Change Data Capture or Change Tracking - Same as Traditional Audit Trail Table?

被刻印的时光 ゝ 提交于 2019-12-30 08:09:07
问题 Before I delve into the abyss of Microsoft documentation any deeper, I'd like to know if someone experienced with Change Data Capture and Change Tracking know if one or both of these can be used to replace the traditional ... "Audit trail table copy of the 'real table' (all of the fields of the original table, plus date/time, user ID, and DML action field) inserted into by Triggers" ... setup for a database table audit trail, where the trigger populates the audit trail table (which is all