This solution documents the steps needed to rename the replicating table(s) on source and/or target. The Shareplex Admin Guide Chapter titled "Changing Oracle Characteristics of Replicated Objects" has a section that delves on this. When dealing with renaming of tables in a peer-to-peer replication environment, there are some additional factors that need to be taken into account. The procedure drafted here is a corollary to the procedure in the Admin Guide.
Need to rename replicating tables in a peer-to-peer environment.
The following is the amended version that can be used for renaming the source and/or target table in a peer-to-peer (or master-master) replication environment:
1. On both nodes make a copy of the existing config file, and edit the copy to make changes to the name of the source and/or target table as needed.
2. Stop user access on the table in question on both nodes.
3. Issue a flush from node 1 to node2 and vice versa.
4. When Post stops on both nodes due to flush, then rename the tables on both nodes. These could be the source and/or target tables. Please bear in mind that if the source and target tables are same, then in a peer-to-peer environment you cannot just rename a source or a target table since nothing is strictly a source or target. However, if the table name on the origin is different from the one on the destination, then we can rename the so called source and target tables selectively.
5. Activate the copy of config file (which was edited to reflect changes to the table names after ALTER TABLE RENAME) on both nodes.
6. When activation finishes on both nodes, start post on both nodes.
© ALL RIGHTS RESERVED. Terms of Use Privacy Cookie Preference Center