Skip to main content

The Working of Microsoft SQL Server CDC

 Modern-day businesses have to preserve historical data and take measures to prevent data breaches. In this regard, Microsoft took the lead in 2005 when it launched the SQL Server CDC.

The 2005 version of SQL Server CDC had certain flaws which were ironed out in an updated release in 2008. Some of the functionalities included tracking and capturing all changes that take place in the SQL Server database tables without taking the help of additional programs and applications. Till 2016, SQL Server CDC was offered by Microsoft in its high-end Enterprise editions but later was available in the Standard version too.

SQL Server CDC captures and records all activities like Insert, Update, and Delete applied to a SQL Server. Column information and metadata required for posting changes to the target database are recorded in modified rows that are then stored in change tables representing the architecture of the columns in the tracked source tables. SQL Server CDC also tracks all changes recorded in the mirrored tables. 



There are additional columns tracking changes at the source tables and the data present is in the following format.

·        __$start_lsn and __$end_lsn that show the commit log sequence number (LSN) assigned by the SQL Server Engine to the recorded change

·        __$seqval that shows the order of that change related to other changes in the same transaction, __$operation that shows the operation type of the change, where 1 = delete, 2 = insert, 3 = update (before change), and 4 = update (after change)

·        __$update_mask that is a bitmask defined for each captured column, identifying updating columns

SQL Server CDC is an excellent method to preserve historical data. 

Comments

Popular posts from this blog

The Change Data Capture (CDC) Feature in Microsoft SQL Server

  Several issues are faced by organizations today in the areas of data security and safety and ramping up systems for preservation of historical data. Leading database platforms took steps in this regard by launching data audits, timestamps, complex queries, and triggers, one of them being Microsoft. It led the innovation when in 2005, it introduced the SQL Server CDC   with the “after date”, “after delete”, and “after insert” features. SQL Server CDC   captures and records all activities like insert, update, or delete that are applied to a SQL Server table. Changes made are available in a user-friendly relational format and metadata and information that are required for posting changes to the target databases are captured in modified rows. These are stored in change tables with the same structure as the columns in the tracked source tables. SQL Server CDC   also tracks and records changes in the mirrored tables with column structures that are the same as the source ...

The SAP BW Extractor and its Operational Features

  SAP BW Extractor   is a program that captures and prepares data in SAP ERP via an extract structure that can be transferred to the BW (Business Warehouse). The program may be customized or run from a standardized Data Source. Both instances define a full process load of various types or a delta load process. The data transfer facets of the SAP BW Extractor can be accessed remotely by the SAP Business Warehouse. Is all data lost if the SAP BW Extractor   is moved to S/4HANA or even other SAP BW Extractors that are compatible with S/4HANA? Only transactional and operational activities can be carried out and not analytics by the SAP ECC system. Thus, to analyze ECC data, SAP BW Extractor   is necessary to extract data from the SAP ECC system to an SAP BW system. After the SAP BW Extractor   is linked to a BW system, the latter can be made to perform analytical activities by connecting to the Business Intelligence system. Data extraction with SAP BW Extra...