diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2021-05-21 15:02:06 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2021-05-21 15:02:06 -0400 |
commit | 2b0ee126bbf01cbfd657bd53c94f9284ba903ca2 (patch) | |
tree | 70d96de4ee059eb932be3b523461efa7929bd341 /src/backend/commands/trigger.c | |
parent | 84f5c2908dad81e8622b0406beea580e40bb03ac (diff) | |
download | postgresql-2b0ee126bbf01cbfd657bd53c94f9284ba903ca2.tar.gz postgresql-2b0ee126bbf01cbfd657bd53c94f9284ba903ca2.zip |
Fix usage of "tableoid" in GENERATED expressions.
We consider this supported (though I've got my doubts that it's a
good idea, because tableoid is not immutable). However, several
code paths failed to fill the field in soon enough, causing such
a GENERATED expression to see zero or the wrong value. This
occurred when ALTER TABLE adds a new GENERATED column to a table
with existing rows, and during regular INSERT or UPDATE on a
foreign table with GENERATED columns.
Noted during investigation of a report from Vitaly Ustinov.
Back-patch to v12 where GENERATED came in.
Discussion: https://postgr.es/m/CAM_DEiWR2DPT6U4xb-Ehigozzd3n3G37ZB1+867zbsEVtYoJww@mail.gmail.com
Diffstat (limited to 'src/backend/commands/trigger.c')
0 files changed, 0 insertions, 0 deletions