Re: Tuples inserted and deleted by the same transaction - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Tuples inserted and deleted by the same transaction
Date
Msg-id 2031521.1663076724@sss.pgh.pa.us
Whole thread Raw
In response to Re: Tuples inserted and deleted by the same transaction  (Laurenz Albe <laurenz.albe@cybertec.at>)
Responses Re: Tuples inserted and deleted by the same transaction
List pgsql-hackers
Laurenz Albe <laurenz.albe@cybertec.at> writes:
> But once they are deleted or updated, even the transaction that created them cannot
> see them any more, right?

I would not trust that claim very far.  The transaction might have active
snapshots with a command ID between the times of insertion and deletion.
(Consider a query that is firing triggers as it goes, and the triggers
are performing new actions that cause the command counter to advance.
The outer query should not see the results of those actions.)

            regards, tom lane



pgsql-hackers by date:

Previous
From: Ranier Vilela
Date:
Subject: Avoid redudant initialization and possible memory leak (src/backend/parser/parse_relation.c)
Next
From: Fujii Masao
Date:
Subject: Re: is_superuser is not documented