For DB2 for Linux, UNIX, and Windows sources, you can use the Data Replication Console to manage the DB2 DATA CAPTURE and DATA CAPTURE CHANGES settings for source tables. To enable supplemental logging, DATA CAPTURE CHANGES must be set for the source tables.
To change DATA CAPTURE settings in the Data Replication Console, the configuration must be open in Edit mode. To only view DATA CAPTURE settings, without making changes, the configuration can be open in Read mode.
On the
Map Tables
tab, click the
Manage Database Supplemental Logging
icon button above the source table
Filter
list.
The
Manage DB2 DATA CAPTURE Settings
dialog box appears.
In the
Schema
list, select the source schema for the tables for which you want to view or edit DATA CAPTURE settings.
The
Schema
list displays only the schemas for which one or more source tables are mapped. By default, the source schema that is currently selected on the
Map Tables
tab is displayed, if it has at least one mapped table.
A list of the mapped source tables in the specified schema appears in the
Tables
box. The following image shows the list of all mapped source tables for the D2D_DDL_5555_T schema:
To display all source tables and schemas, including unmapped tables and schemas, select
Show all objects
. To display only the tables for which DATA CAPTURE CHANGES is not set, select
Show only the tables for which DATA CAPTURE CHANGES is not set
. To filter the list of source tables, enter the first few letters of a table name in the
Table Filter
field. For case-sensitive filtering, enclose the filter value in double quotation marks.
If the source schema contains thousands of tables or the Data Replication Console runs in a local area network that is remote to the database server network, selecting
column, select the check box for each source table for which you want to set DATA CAPTURE CHANGES to enable supplemental logging, or clear the check box for any table for which you want to set DATA CAPTURE NONE to disable supplemental logging.
To select the
Data Capture
check box for all of the source tables, click
Select All
. To clear the
Data Capture
check box for all of the source tables, click
Clear All
. To revert to the
Data Capture
settings that appeared when you first opened the
Manage DB2 DATA CAPTURE Settings
dialog box, click
Reset
. To refresh the Data Capture settings to get the latest changes made in the source database or from the Server Manager CLI, click
Refresh
.
Data Replication generates SQL statements for each table for which you edited the
Data Capture
settings. Data Replication uses the following syntax for the statements:
ALTER TABLE "
schema_name
"."
table_name
" DATA CAPTURE CHANGES INCLUDE LONGVAR COLUMNS;
ALTER TABLE "
schema_name
"."
table_name
" DATA CAPTURE NONE;
The DATA CAPTURE CHANGES statement enables supplemental logging for the table that you selected, and the DATA CAPTURE NONE statement disables supplemental logging for the table that you selected.
To save the SQL statements to a script file, perform the following substeps:
Click
Save
.
The
Save
dialog box appears.
Enter a file name and path and click
Save
.
A message confirms that the script file was saved successfully.
Click
OK
.
You can use the saved script file to run the SQL statements later. If you do not have the authority to run the SQL statements or manage DATA CAPTURE settings, give the script file to a database administrator who has the authority to run the statements.
To run the SQL statements before exiting the dialog box, click
Run
.
Click
Close
.
If you set DATA CAPTURE CHANGES to enable supplemental logging for any unmapped source tables, map these tables on the
Map Tables
tab to include them in the replication configuration.