Distributed Databases   «Prev  Next»

Lesson 5 Updateable Snapshots are legacy
Objective Identify the features that Oracle has for updateable snapshots.

Oracle GoldenGate in Oracle Database 23c for advanced replication scenarios:

With "Oracle GoldenGate", which is fully compatible with Oracle Database 23c, you can implement advanced data replication scenarios that go far beyond traditional updateable snapshots. GoldenGate enables real-time, bidirectional replication between heterogeneous systems, allowing for high availability, scalability, and minimal downtime during migrations and upgrades.
GoldenGate supports partial replication by allowing you to replicate only specific columns or rows from source tables to target tables. When changes are made to a remote (target) table, these changes can be replicated back to the source (master) in near real time, enabling bidirectional synchronization. This replaces the older updateable snapshot mechanism, which allowed updates on snapshot copies to be propagated back to the master table.
Unlike legacy snapshots that were originally read-only and required users to connect to the master table to perform updates, GoldenGate provides a multimaster replication architecture, where each participating database can function as both a source and a target. Updates at one site can be cascaded to all other replication sites, maintaining consistency across the enterprise.
Oracle GoldenGate offers several compelling benefits over traditional snapshot replication:
  • Low-latency data replication with minimal performance impact
  • Support for conflict detection and resolution in active-active setups
  • Seamless integration with cloud and hybrid database environments
  • Fine-grained control over data transformation and filtering during replication

Real-time Data Replication and Synchronization Technology

Here is the updated version of your text and SQL code using Oracle GoldenGate, which replaces the legacy updateable snapshot mechanism and is designed for modern, high-performance replication in Oracle Database 23c:
Oracle GoldenGate, a real-time data replication and synchronization technology, is the modern replacement for updateable primary key snapshots. Unlike traditional snapshot replication that required a `FOR UPDATE` clause and grouping via snapshot groups, GoldenGate enables "bidirectional replication" across distributed systems without relying on snapshot-specific SQL constructs. To replicate changes from a remote source (e.g., the `CUSTOMER` table in the `DENVER` database) and ensure updates can be applied bidirectionally, you configure replication mappings and enable DML capture and apply processes using GoldenGate.
Here is how the equivalent logic is defined using Oracle GoldenGate:
  1. Extract and Replicat Configuration

    • -- Extract Parameter File: EXT_CUST
      EXTRACT EXT_CUST
      USERID ggadmin, PASSWORD ggadminpwd
      EXTTRAIL ./dirdat/ec
      TABLE DENVER.CUSTOMER;
      
    • -- Replicat Parameter File: REP_CUST
      REPLICAT REP_CUST
      USERID ggadmin, PASSWORD ggadminpwd
      MAP DENVER.CUSTOMER, TARGET LOCALDB.CUSTOMER, KEYCOLS(CUST_ID);
      
  2. Replication Explanation
    • DENVER.CUSTOMER is the source table from the remote site.
    • LOCALDB.CUSTOMER is the target table on the local site.
    • KEYCOLS(CUST_ID) ensures that GoldenGate uses the primary key to identify rows for updates.
    • Changes captured on either side can be pushed to the other in real time, enabling active-active replication.
This architecture eliminates the need for snapshot groups and the `FOR UPDATE` clause. Instead, Oracle GoldenGate ensures transactional consistency and near-zero latency replication while offering superior conflict resolution and support for enterprise-scale deployments. In the next lesson, we will review deferred constraints and how Oracle GoldenGate handles constraint enforcement in multi-master environments.
 GoldenGate Based Replication in Oracle 23c
GoldenGate Based Replication in Oracle 23c

Using Updateable Snapshots - Quiz

Click the Quiz link below to test your understanding of new snapshot features.
Using Updateable Snapshots - Quiz
The next lesson reviews another new feature for snapshots called deferred constraints.

SEMrush Software Target 5SEMrush Software Banner 5