Skip site navigation (1) Skip section navigation (2)

Re: PG_PAGE_LAYOUT_VERSION 5 - time for change

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Gregory Stark <stark(at)enterprisedb(dot)com>, Zdenek Kotala <Zdenek(dot)Kotala(at)Sun(dot)COM>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PG_PAGE_LAYOUT_VERSION 5 - time for change
Date: 2008-10-31 07:40:04
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
Tom Lane wrote:
> Gregory Stark <stark(at)enterprisedb(dot)com> writes:
>> Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:
>>> ... 3b sounds good until you
>>> reflect that a genuinely variable chunk size would preclude random
>>> access to sub-ranges of a toast value.  
>> Hm, Heikki had me convinced it wouldn't but now that I try to explain it I
>> can't get it to work. I think the idea is you start a scan at the desired
>> offset and scan until you reach a chunk which overruns the end of the desired
>> piece. However you really need to start scanning at the last chunk *prior* to
>> the desired offset.
> Yeah, that was my conclusion too.

Hmm, you're right. I think it can be made to work by storing the *end* 
offset of each chunk. To find the chunk containing offset X, search for 
the first chunk with end_offset > X.

   Heikki Linnakangas

In response to


pgsql-hackers by date

Next:From: Craig RingerDate: 2008-10-31 08:00:08
Subject: Re: Decreasing WAL size effects
Previous:From: Craig RingerDate: 2008-10-31 07:06:27
Subject: Re: Decreasing WAL size effects

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group