Replication Guide and Reference
The following steps describe how to set up the sources and targets for
update-anywhere replication. They do not list all the possible steps for
defining the source and subscription; just those of particular interest when
administering an update-anywhere scenario.
To define a replication source and subscription for update
anywhere:
- Define a custom replication source, using the following selections. See "Defining Replication Sources" to learn how to define a replication source.
- Ensure that the Define as Source check boxes is selected for
every column.
- Ensure that the Capture before image check boxes is selected
for every column.
- Click on the Table will be used for update anywhere check box.
- Select a conflict detection level.
- Define a replication subscription set using the following selections. See "Defining Replication Subscriptions" for information about the steps for this task.
- Select the replication sources to be in the subscription set. Include all
sources affected by the replica tables being updated.
- From the Subscription Definition window, select a target table to be
defined as a replica, an updateable target table.
- Click on Advanced to open the Advanced Subscription notebook.
The following sections are required on the Advanced Subscription
notebook:
- From the Target Table page, click on Target table is
replica.
- From the Target Columns page:
- Ensure that the Subscribe check boxes are selected for every
column. Do not create new columns for the replica table.
- Specify a primary key for the replica table by clicking on the
Primary Key check boxes next to the key column names.
Note: | Make the primary key the same as the source table primary key to prevent
conflicts.
|
- If you want the replica to be a subset of the source table, from the Rows
page, type a row predicate in the WHERE field.
- Click on OK to close the Advanced Subscription notebook.
- Repeat the Advanced Subscription notebook steps for each target table.
- Click on Timing to open the Subscription Timing notebook.
- On the Source to Target page, fill in the subscription set timing
information for copying the source tables changed data to the target tables.
- On the Replica to Target page, fill in the subscription set timing
information for copying the replica tables changed data to the source tables.
- Click on OK to close the notebook.
- If you want to define SQL or CALL procedures to run before or after the
subscription set is processed, click on SQL and define the
processing statements.
[ Top of Page | Previous Page | Next Page | Table of Contents | Index ]
[ DB2 List of Books |
Search the DB2 Books ]