Updated on 2024-11-30 GMT+08:00

Checking Replication Attribute of Primary Key Columns

During a full+incremental synchronization or an incremental synchronization task with PostgreSQL serving as the source database, the replication attribute of primary key columns in the source database table is checked. If the toast attribute of the primary key column in the source database is main, external, or extended, the replica identity attribute must be full.

Failure Cause

  • All primary key columns of the tables to be synchronized are columns whose storage attribute is plain, and the replication attribute of the tables is neither full nor default. Incremental synchronization may fail.
  • The primary key columns of the tables to be synchronized contain columns whose storage attribute is not plain, and the replication attribute of the tables is neither full nor default. There is a high probability that incremental synchronization will fail.
  • The primary key columns of the tables to be synchronized contain columns whose storage attribute is not plain, and the replication attribute of the tables is not full. Incremental synchronization may fail.

Handling Suggestion

Run the following SQL statement to change the replication attribute of the tables to full: (If the replication attribute is changed to default, incremental synchronization may still fail.)

alter table schema.table replica identity full;