On 2/12/07, Heikki Linnakangas <[EMAIL PROTECTED]> wrote:
Hannu Krosing wrote:
> Ühel kenal päeval, P, 2007-02-11 kell 12:35, kirjutas Tom Lane:
>> Hannu Krosing <[EMAIL PROTECTED]> writes:
>>> What if we would just reuse the root tuple directly instead of turning
>>> it into a stub ?
>>> This would create a cycle of ctid pointers, which changes the lookup
>>> process from 'follow ctid chaint until the end' to 'follow the tid
>>> until you reach the start'.
>> How do you know which one is newest?
> By xmin,cmin of course .
>> What happens when you have to put a newer version off-page for lack of
> Then this scheme won't work.
Couldn't the ctid of the latest tuple point to the off-page tuple as
It could. But then you may lose reference for older version(s). We can do
the whole page scans to locate older versions, but that might prove too
It might be acceptable, if it was only stored on those tuples that are
(HOT) updated. But it's not clear to me what you're proposing to do with
the field, anyway, Which tuples would have it, and what would it point to?
My guess what Hannu is suggesting is to have a circular chain of
tuples in a page. The index can point to any tuple in the chain. When
update goes off-page or is a COLD update, t_ctid points to the newer version
as usual. So a tuple which is COLD updated would need two pointers, one
which points to the oldest version in the circular on-page chain and other
points to the new version.