Defining a rule set for a subscription

If you are replicating DDL operations, you need to create a rule set for your subscription.

Procedure

  1. Click Configuration > Subscriptions.
  2. Select a subscription.
  3. Click Rules in the Table Mappings view.
  4. Right-click in the view and select Define Rule Set....
  5. Enter the name of the rule in the Rule Set Name box.

    Each rule set name within a subscription must be unique.

  6. Click Next.
  7. Select the schema.
    You may be prompted to filter schemas if Automatically prompt for filter when expanding nodes is enabled in your preferences. For more information see, Setting advanced preferences. To manually define a filter, select the datastore name and click Specify Filter.
    Note: For the CDC Replication Engine for Db2® Database, the CDC Replication user's schema will not be available for inclusion in a rule set.
  8. Click Next.
  9. If you choose to manually select which tables to include in the rule set, perform the following steps:
    1. Click Add Table...
    2. Select the tables to be included in the rule set.
    3. Click OK.
  10. If you choose to use a pattern within the table names to select which tables to include in the rule set, perform the following steps:
    1. Click Add Pattern...
    2. Specify a value in the Pattern box.

      Patterns are case-sensitive.

    3. Determine how to apply the pattern. Select one of the following options:
      Match all tables
      Specifies that any defined patterns will be overridden and all tables will be considered for replication.
      Matches the pattern
      Specifies that tables with names that match the pattern will be included in the rule set.
      Starts with the pattern
      Specifies that tables with names that match the pattern at the beginning of their names will be included in the rule set.
      Contains the pattern
      Specifies that tables with names that contain the pattern in any part of their names will be included in the rule set.
      Ends with the pattern
      Specifies that tables with names that match the pattern at the end of their names will be included in the rule set.
    4. Click OK to add the pattern and exit the dialog box.

      Alternately, click Add if you want to create another pattern.

  11. Select the Replicate structural changes only checkbox if you want to replicate only structural, not data, changes for the tables.
  12. Click Next.
  13. If you choose to manually select which tables to exclude from the rule set, perform the following steps:
    1. Click Add Table...
    2. Select the tables to be excluded from the rule set.

      You cannot exclude all tables.

    3. Click OK.
  14. If you choose to use a pattern within the table names to select which tables to exclude from the rule set, perform the following steps:
    1. Click Add Pattern...
    2. Specify a value in the Pattern box.

      Patterns are case-sensitive.

    3. Determine how to apply the pattern. Select one of the following options:
      Matches the pattern
      Specifies that tables with names that match the pattern will be excluded from the rule set.
      Starts with the pattern
      Specifies that tables with names that match the pattern at the beginning of their names will be excluded from the rule set.
      Contains the pattern
      Specifies that tables with names that contain the pattern in any part of their names will be excluded from the rule set.
      Ends with the pattern
      Specifies that tables with names that match the pattern at the end of their names will be excluded from the rule set.
    4. Click OK to add the pattern and exit the dialog box.

      Alternately, click Add if you want to create another pattern.

  15. Click Next.
  16. Select one of the following options and click Finish:
    Show rule set details
    Completes the rule set definition and displays it in the Details area of the Rules view.
    Create a new rule set
    Completes the rule set definition and opens a new instance of the Define Rule Set wizard, allowing for the creation of a new rule set.
    Return to the rules view
    Completes the rule set definition and returns you to the Rules view.