Replicas in a geodatabase in DB2

You can use geodatabase replication to create copies of data across two or more versioned geodatabases so that changes to the data can be synchronized. A synchronization involves one replica sending data changes and the relative replica receiving changes.

Before you create a two-way or one-way replica, you must add a GlobalID column to the datasets to be replicated. This gives the rows in the dataset a unique value that will remain constant across geodatabases. (For details on getting a dataset ready for replication, consult Preparing data for replication.)

After changes have been made in one of the replicas, you can synchronize the geodatabases, bringing the changes made in one geodatabase into its relative geodatabase. When a geodatabase is synchronized with its relative geodatabase, a table is created in the user's schema of the replica geodatabase (the one that is sending the changes to the relative geodatabase) to track the lineages of altered datasets.

Replica tables in ArcGIS Desktop

You cannot see the table used for synchronization in ArcGIS Desktop; it is used behind the scenes and only during synchronization.

However, you can identify if a geodatabase is being used as a replica geodatabase by checking its properties in the Catalog window. Right-click the geodatabase and click Properties. On the General tab, there is a Distributed Geodatabase Status section. If the geodatabase has been replicated or replicated to, the status message states "This is a replica geodatabase".

In ArcMap, you know an MXD file contains one or more layers that have been replicated because most (or even all) of the tools on the Distributed Geodatabase toolbar are active. Also, when you open the Replica Manager, one or more replicas are listed.

Replica tables in an IBM DB2 database

Before datasets can be replicated, they must have a GlobalID column and be registered as fully versioned (not registered with the option to save edits to base). Therefore, in the database, the business tables of any datasets that are included in the replica have a GUID column and delta tables.

Replicas are tracked in the database in the GDB_ITEMS, GDB_ITEMRELATIONSHIPS, and GDB_REPLICALOG ArcSDE geodatabase system tables. The fact that it is a replica is recorded in the GDB_ITEMTYPES system table. See System tables of a geodatabase in DB2.

The tables are related as follows:

Replica tables in DB2

Dashed lines indicate implicit relationships between columns.

When synchronization is performed between two geodatabases, a temporary table is created to track dataset lineages.

Replica tables in an XML document

If you choose to replicate to an XML document when you create your replica, information about the replica and replicated datasets is enclosed in <GPReplica> tags as shown below.

In this example, the name of the replica is india, and it was replicated from geodatabase version edits1.

<GPReplica xsi:type="esri:GPReplica">
  <GPReplicaDescription xsi:type="esri:GPReplicaDescription">
  <QueryGeometry xsi:type="esri:EnvelopeN">
  <SpatialReference xsi:type="esri:ProjectedCoordinateSystem">
   <WKT>PROJCS["Asia_South_Albers_Equal_Area_Conic", GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984", SPHEROID["WGS_1984",6378137.0,298.257223563]], PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]], PROJECTION["Albers"], PARAMETER["False_Easting",0.0], PARAMETER["False_Northing",0.0], PARAMETER["Central_Meridian",125.0], PARAMETER["Standard_Parallel_1",7.0], PARAMETER["Standard_Parallel_2",-32.0], PARAMETER["Latitude_Of_Origin",-15.0], UNIT["Meter",1.0]], VERTCS["Ha_Tien_1960",VDATUM["Ha_Tien_1960"], PARAMETER["Vertical_Shift",0.0], PARAMETER["Direction",1.0], UNIT["Meter",1.0]]</WKT> 
 <GPReplicaDatasets xsi:type="esri:ArrayOfGPReplicaDataset">
  <GPReplicaDataset xsi:type="esri:GPReplicaDataset">

Other dataset definitions


Related Topics