Temp tables and replication identities - Mailing list pgsql-general

From Michael Lewis
Subject Temp tables and replication identities
Date
Msg-id CAHOFxGpnP3Pf5bWRhyP-3NxgtfJsTNMzo0YtvNC75iB+4a=eTw@mail.gmail.com
Whole thread Raw
List pgsql-general
I am curious about receiving an error on updating/inserting into a temp table when a replication for "all tables' is created in PG 10.6. Given temp tables are not replicated, it seems odd that an update fails unless a replication identity is defined.

To reproduce, try the below code. Uncomment line 3 and the error is gone of course. It just seems like the identity should not be need to be defined on a temp table since it won't be replicated anyway.

CREATE publication test1 FOR ALL TABLES;
CREATE TEMP TABLE testing123 ON COMMIT DROP AS ( SELECT 1 AS value );
/* ALTER TABLE pg_temp.testing123 REPLICA IDENTITY FULL; */
UPDATE testing123 SET value = 2;


Michael Lewis  |  Software Engineer
Entrata

pgsql-general by date:

Previous
From: github kran
Date:
Subject: Postgresql RDS DB Latency Chossing Hash join Plan
Next
From: Michael Lewis
Date:
Subject: Re: Postgresql RDS DB Latency Chossing Hash join Plan