pgsql: Fix heap_multi_insert to set t_self field in the caller's tuples

From: Heikki Linnakangas <heikki(dot)linnakangas(at)iki(dot)fi>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix heap_multi_insert to set t_self field in the caller's tuples
Date: 2012-02-13 08:23:42
Message-ID: E1RwrCI-00044D-I6@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix heap_multi_insert to set t_self field in the caller's tuples.

If tuples were toasted, heap_multi_insert didn't update the ctid on the
original tuples. This caused a failure if there was an after trigger
(including a foreign key), on the table, and a tuple got toasted.

Per off-list report and test case from Ted Phelps

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/21b16342750d6623f3c78f639f07bf3b66b49417

Modified Files
--------------
src/backend/access/heap/heapam.c | 8 ++++++++
1 files changed, 8 insertions(+), 0 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Andrew Dunstan 2012-02-13 13:23:55 pgsql: Fix auto-explain JSON output to be valid JSON.
Previous Message Heikki Linnakangas 2012-02-13 07:20:15 Re: [COMMITTERS] pgsql: Add new keywords SNAPSHOT and TYPES to the keyword list in gram.