Re: Another Idea: Try Including snapshot with TOAS (was: Including Snapshot Info with Indexes)

Поиск
Список
Период
Сортировка
От Simon Riggs
Тема Re: Another Idea: Try Including snapshot with TOAS (was: Including Snapshot Info with Indexes)
Дата
Msg-id 1191850837.4223.533.camel@ebony.site
обсуждение исходный текст
Ответ на Another Idea: Try Including snapshot with TOAS (was: Including Snapshot Info with Indexes)  (Hannu Krosing <hannu@skype.net>)
Ответы Re: Another Idea: Try Including snapshot with TOAS (was: Including Snapshot Info with Indexes)  ("Gokulakannan Somasundaram" <gokul007@gmail.com>)
Список pgsql-hackers
On Mon, 2007-10-08 at 14:58 +0300, Hannu Krosing wrote:

> 1. get rid of indexes for TOAST tables
> 
> instead of TOAST tuple id store CTID of first TOAST block directly, and
> use something like skip lists inside the TOAST block headers to access
> next TOAST tuples.

It should be possible to optimise TOAST for when there is just a single
chunk that is toasted. Since we often (and by default) compress data
stored in TOAST tables this would be a frequently used optimisation. 

Instead of storing the TOAST OID, which is then looked-up in the index
to find the TOAST tid, we can just store the tid directly in the toast
pointer on the main heap. That way we'll get faster read and write
access for a good proportion of rows by avoiding the toast index and
going straight to the toast heap.

We'd need a different kind of toast pointer which would be 2 bytes
longer than the normal pointer. I think we have a spare flag bit to
indicate this.

That's just a rough sketch, I've not checked the details on this.

--  Simon Riggs 2ndQuadrant  http://www.2ndQuadrant.com



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andrew Dunstan
Дата:
Сообщение: Re: proposal casting from XML[] to int[], numeric[], text[]
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Improving the Performance of Full Table Updates