Xtract Table CDC
This page shows how to use the Xtract TableCDC component.
The Xtract TableCDC component can be used to extract delta content from SAP Tables. It creates a log table in SAP that records insert, update, and delete activities that apply to a selected SAP table.
Note
Table CDC is an Add-On that requires a license. For more information, contact Theobald Software's sales team at sales@theobald-software.com.
About Table CDC
Change Data Capture (CDC) is a method to keep track of data changes such as insert, update and delete in SAP tables. The Table CDC component creates a log table in SAP that records any changes made to a selected table. The content of the log table is cleared after every successful run of the extraction. Data that was not extracted is not cleared from the log table.
For a detailed overview of this process, refer to the Knowledge Base article Delta Mechanism of TableCDC.
Note
Clusters, pool tables and views are not supported by the Xtract TableCDC component.
System Requirements
- The Xtract TableCDC component is compatible with SAP ECC 5.0 and higher
- Supported databases:
- HANA
- SQL Server
- Oracle
- IBM Db2
- IBM for i (Db4)
- IBM for z/os (Db6)
- MaxDB
Prerequisites
- SAP custom function module /THEO/CDC_ECC or /THEO/CDC_S4 is installed in SAP.
- SAP custom function module /THEO/READ_TABLE or Z_THEO_READ_TABLE version 2.10 or higher is installed in SAP.
- A connection to an SAP system is available, see SAP Connection.
- The SAP user has sufficient user rights, see SAP Authority Objects.
The SAP transport requests for the function modules are provided in the installation directory: C:\Program Files\XtracIS\ABAP\
, see Custom function module for TableCDC.
Warning
Missing Authorization.
To use the Xtract Table CDC component, access to the designated authority objects (RFC) in SAP must be available. Adjust SAP Authority Objects accordingly.
Add an Xtract Table CDC Component
Follow the steps below to add an Xtract Table component to your SSIS package:
- Drag&drop the Xtract Table CDC component from the SSIS toolbox into your data flow task.
-
Double-click the component. A connection manager is automatically assigned to the component and the main window of the component opens.
Note
If there are multiple connection managers, the window "Select Connection Manager" opens, see SAP Connection. Once a connection manager is selected, the main window of the component opens.
The majority of the functions of the component can be accessed in the main window.
Look Up a Table
- In the main window of the component, click [ ]. The window “Table Lookup” opens.
- In the field Table Name, enter the name of the table to track and extract . Use wildcards (*) if needed.
- Click [ ] . Search results are displayed.
- Select a table and click [OK].
All relevant metadata information of the table is retrieved from SAP. The application returns to the main window of the component.
Define the Xtract TableCDC Component
The Xtract TableCDC component offers the following options for tracking SAP tables:
- Select the table columns you want to track and extract. By default all columns are selected. Deselect the columns you do not want to extract.
- If you want to extract the table when first running the extraction, activate [Extract table on first run].
-
Optional: You can set a maximum number of rows that the log table can contain. The default is disabled (Value 0).
If the row limit is reached, the extraction fails with an exception. The maximum row limit of a log table is 500.000.Note
Once a log table is initialized, you cannot change the size limit anymore.
-
Optional: Define a WHERE Clause to filter table records. By default all data is extracted.
- Click [Load live preview] to display a live preview of the first 1000 records.
- The column TS_TIMESTAMP contains a timestamp of when the data was last changed.
- The column TS_OPERATION indicates if a row was inserted (I), updated (U) or deleted (D).
- Check the Settings before running the SSIS package.
- Click [OK] to confirm your settings.
To initialize the tracking of the selected SAP table, run the SSIS package once.
Run the Extraction for the First Time
Run the extraction for the first time to create a log table in SAP that records any changes made to a selected table or view.
- If the option [Extract table on first run] in the Xtract TableCDC component is active, the extracted table contains the original SAP table.
- If the option [Extract table on first run] in the Xtract TableCDC component is not active, the extracted table is empty.
The log table in SAP is now available for the Table CDC component. The extracted SAP table is now available in your destination.
Note
When running the extraction regularly the content of the log table in SAP is extracted and written to the destination. The content of the log table in SAP is cleared after every successful run of the extraction. Data that was not extracted is not cleared.
Delete Log Table and Triggers
When a Table CDC extraction is no longer in use or if you need to change the structure of the source table, simply deleting the extraction is not enough. To delete the log table and all associated triggers from your SAP system, open the Table CDC extraction and click [Delete CDC resources].
To delete the SAP resources of multiple extractions or extractions that are already deleted, see Active CDC Watches.
Warning
Table change not possible
The source table cannot be changed, if any CDC-related resources connected to the source table in SAP exist.
Clear the CDC-related resources connected to the source table in SAP, see SAP Note 2284776.