pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Álvaro Herrera <alvherre@kurilemu.de>
To: dbman@sqlexec.com <dbman@sqlexec.com>
Cc: David G. Johnston <david.g.johnston@gmail.com>
Cc: pgsql-bugs@lists.postgresql.org <pgsql-bugs@lists.postgresql.org>
Subject: Re: BUG #19013: When creating a table with the "...LIKE...INCLUDING ALL" construct, REPLICA IDENTITY output is wrong
Date: Wed, 6 Aug 2025 20:04:37 +0200
Message-ID: <202508061804.wwf4zc7npayp@alvherre.pgsql> (raw)
In-Reply-To: <cf5057c2-b9f9-4a18-961b-de3d22897650@sqlexec.com>

On 2025-Aug-06, dbman@sqlexec.com wrote:

> Good point aboutg the default value for pg_class.relreplident is always "d",
> but maybe it should be "n" which indicates there is no REPLICA IDENTITY. 

I think this behavior is just an oversight made when replica identity
was introduced.  Commit 07cacba983ef didn't touch the CREATE TABLE LIKE
code.

To me, it makes sense to copy the replica identity definition if
INCLUDING INDEXES or INCLUDING CONSTRAINTS is given.

Patching released branches seems out of the question (it might disrupt
working workflows), but for 19 it isn't, if we agree on an ideal
behavior.

-- 
Álvaro Herrera        Breisgau, Deutschland  —  https://www.EnterpriseDB.com/
"Siempre hay que alimentar a los dioses, aunque la tierra esté seca" (Orual)





view thread (9+ messages)  latest in thread

Message-ID: <202508061804.wwf4zc7npayp@alvherre.pgsql>
Permalink:  ../202508061804.wwf4zc7npayp@alvherre.pgsql/
Also on:    postgresql.org/message-id/202508061804.wwf4zc7npayp@alvherre.pgsql

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-bugs@postgresql.org
  Cc: alvherre@kurilemu.de, dbman@sqlexec.com, david.g.johnston@gmail.com, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #19013: When creating a table with the "...LIKE...INCLUDING ALL" construct, REPLICA IDENTITY output is wrong
  In-Reply-To: <202508061804.wwf4zc7npayp@alvherre.pgsql>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox