BUG #19952: psql \d+ omits nondefault replica identity for partitioned tables

From: PG Bug reporting form <noreply(at)postgresql(dot)org>
To: pgsql-bugs(at)lists(dot)postgresql(dot)org
Cc: imchifan(at)mail(dot)com
Subject: BUG #19952: psql \d+ omits nondefault replica identity for partitioned tables
Date: 2026-11-25 17:42:11
Message-ID: 19952-0ef0a4ab62beb6b5@postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

The following bug has been logged on the website:

Bug reference: 19952
Logged by: Faye
Email address: imchifan(at)mail(dot)com
PostgreSQL version: 19.0
Operating system: Linux/amd64
Description:

psql's \d+ does not display a partitioned table's nondefault replica
identity, although ALTER TABLE accepts the setting and pg_class records it.
The equivalent setting is displayed for an ordinary table.

Run as a superuser.

This can be reproduced with psql -X -f repro.sql:

\set ON_ERROR_STOP on
CREATE TABLE t_regular (id integer);
CREATE TABLE t_partitioned (id integer) PARTITION BY RANGE (id);
ALTER TABLE t_regular REPLICA IDENTITY FULL;
ALTER TABLE t_partitioned REPLICA IDENTITY FULL;

\pset format unaligned
\pset tuples_only on
SELECT relname || '|' || relkind::text || '|' || relreplident::text
FROM pg_class
WHERE relname IN ('t_regular', 't_partitioned')
ORDER BY relname;

\pset format aligned
\pset tuples_only off
\d+ t_regular
\d+ t_partitioned

The catalog query shows that both settings are FULL (`relreplident = 'f'`):

t_partitioned|p|f
t_regular|r|f

The ordinary table's description includes:

Replica Identity: FULL
Access method: heap

The partitioned table's description ends without the corresponding replica
identity line:

Partition key: RANGE (id)
Number of partitions: 0

Since REPLICA IDENTITY FULL is stored for the partitioned table, I expected
its \d+ output to include `Replica Identity: FULL` as it does for the
ordinary table.

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message PG Bug reporting form 2026-11-25 17:46:20 BUG #19953: pg_stat_io exposes impossible rows for io worker backends
Previous Message PG Bug reporting form 2026-11-25 17:38:01 BUG #19951: levenshtein_less_equal returns 0 when exact distance is 1 with a negative cost