postgresql/src
Álvaro Herrera 3be823486f
Fix REPACK CONCURRENTLY for stored generated columns
In order to replay concurrent changes, REPACK CONCURRENTLY needs the
pg_attrdef tuples for the transient table to be there, in case a tuple
is modified concurrently with REPACK and requires to store the value
from the generated column (which, with the current arrangements, means
all tuples concurrently updated or inserted).  Fix by creating a copy of
them from the original table.  Add a test that tickles the bug.

Author: Antonin Houska <ah@cybertec.at>
Reported-by: Ewan Young <kdbase.hack@gmail.com>
Diagnosed-by: Ewan Young <kdbase.hack@gmail.com>
Reviewed-by: Ewan Young <kdbase.hack@gmail.com>
Backpatch-through: 19
Discussion: https://postgr.es/m/CAON2xHMrELwx9vKg6niSf8fMBA=-MGXmG=MPQU6+vMVhGjF8kQ@mail.gmail.com
2026-07-03 12:22:37 +02:00
..
backend Fix REPACK CONCURRENTLY for stored generated columns 2026-07-03 12:22:37 +02:00
bin psql: Fix \df tab completion for procedures 2026-07-03 13:48:59 +09:00
common Fix mismatched deallocation functions 2026-07-01 13:50:08 +02:00
fe_utils Fix mismatched deallocation functions 2026-07-01 13:50:08 +02:00
include Switch Get[Local]BufferDescriptor() to use a signed value in input 2026-07-03 12:07:30 +09:00
interfaces Fix mismatched deallocation functions 2026-07-01 13:50:08 +02:00
makefiles Add CONCURRENTLY option to REPACK 2026-04-06 21:55:08 +02:00
pl plpython: Fix NULL pointer dereferences for broken sequence and mapping objects 2026-06-29 11:38:39 +09:00
port Use C11 alignas instead of pg_attribute_aligned 2026-07-01 08:36:43 +02:00
template Switch the semaphore API on Solaris to unnamed POSIX. 2026-03-14 14:10:32 -04:00
test Fix REPACK CONCURRENTLY for stored generated columns 2026-07-03 12:22:37 +02:00
timezone Fix macro-redefinition warning introduced by aeb07c55f. 2026-07-01 13:44:45 -04:00
tools Allow logical replication conflicts to be logged to a table. 2026-07-02 08:26:07 +05:30
tutorial Pre-beta mechanical code beautification, step 1: run pgindent. 2026-05-13 10:34:17 -04:00
.gitignore
DEVELOPERS
Makefile Add CONCURRENTLY option to REPACK 2026-04-06 21:55:08 +02:00
Makefile.global.in Update Unicode data to CLDR 48.2 2026-04-13 11:13:36 +02:00
Makefile.shlib Restore AIX support. 2026-02-23 13:34:22 -05:00
meson.build Update copyright for 2026 2026-01-01 13:24:10 -05:00
nls-global.mk Fix update-po for the PGXS case 2025-10-16 20:21:05 +02:00