[Patch] Omit virtual generated columns from test_decoding output

From: SATYANARAYANA NARLAPURAM <satyanarlapuram(at)gmail(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: [Patch] Omit virtual generated columns from test_decoding output
Date: 2026-05-05 01:11:11
Message-ID: CAHg+QDfTh3UbB-Ed--o2Bd=SBDJoEiG-qp3C0+ETDibF63y=dw@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Hackers,

Virtual generated columns are not stored on disk, so heap_getattr() in
tuple_to_stringinfo() always returned NULL for them, producing
misleading output such as

table public.t: INSERT: a[integer]:1 b[integer]:10 c[integer]:null

even though the user could observe a non-null value via SELECT. Stored
generated columns continue to be emitted as before because their values
do live in the heap tuple.

This matches the pgoutput's logicalrep_should_publish_column()
which never publishes virtual generated columns. Added a regression test.
Please find the patch attached.

Thanks,
Satya

Attachment Content-Type Size
0001-Omit-virtual-generated-columns-from-test_decoding-ou.patch application/octet-stream 7.3 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Richard Guo 2026-05-05 02:06:58 Re: Wrong results from inner-unique joins caused by collation mismatch
Previous Message Tatsuo Ishii 2026-05-05 00:01:24 Re: Row pattern recognition