Re: Logical replication without a Primary Key - Mailing list pgsql-hackers

From David G. Johnston
Subject Re: Logical replication without a Primary Key
Date
Msg-id CAKFQuwZYqGRF-66e1tOWtmdk7qUi3PXnAsswF=T6-e1ZaB6r+Q@mail.gmail.com
Whole thread Raw
In response to Re: Logical replication without a Primary Key  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
List pgsql-hackers
On Thursday, December 7, 2017, Peter Eisentraut <peter.eisentraut@2ndquadrant.com> wrote:
On 12/6/17 19:03, Joshua D. Drake wrote:

>
> How does that work? Is it using one of the hidden columns on a row?

It means that for example if an update record is produced, the entire
row is included in the record as the key.


IOW, IIUC, whether defined or not the user data portion of the table must, as a whole, provide a natural unique key if you are going to use logical replication.  If two records only differ in their OID (or maybe ctid?) value you will have problem.

David J.

pgsql-hackers by date:

Previous
From: "Joshua D. Drake"
Date:
Subject: Re: Logical replication without a Primary Key
Next
From: Craig Ringer
Date:
Subject: Re: Logical replication without a Primary Key