Re: Nested transactions and tuple header info

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
Cc: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>, Manfred Koizar <mkoi-pg(at)aon(dot)at>, David Blasby <dblasby(at)refractions(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Nested transactions and tuple header info
Date: 2004-06-02 03:44:13
Message-ID: 19674.1086147853@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> Tom Lane wrote:
>> You can't change xmin --- this would break visibility tests.

> Basically the phantom xid's are a shorthand for saying the tuple was
> created by xid1 and deleted by xid2, both part of the same main
> transaction.

That would be fine if the shorthand were readable, but it's not.

> A cursor looking at the rows has to recognize the xid is a phantom (via
> pg_subtrans) and look up the creation xid.

And it will find that how? Imagine that the creating transaction is
itself a subtransaction, and the deleting one is a few nesting levels
further down. I don't see how the tuple is going to carry enough
information to let you determine what's what, if the deleting subxact
overwrites the creating one's XID.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 2004-06-02 03:50:13 Re: Nested transactions and tuple header info
Previous Message Tom Lane 2004-06-02 03:39:57 Re: Why repalloc() != realloc() ?