Re: Tid scan improvements

Поиск
Список
Период
Сортировка
От David Rowley
Тема Re: Tid scan improvements
Дата
Msg-id CAKJS1f8FyS51b6j++qShP_av5Kq1oq83t16ALPftPm4F0BbqkQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Tid scan improvements  (Edmund Horner <ejrh00@gmail.com>)
Ответы Re: Tid scan improvements  (Edmund Horner <ejrh00@gmail.com>)
Список pgsql-hackers
On 15 August 2018 at 11:11, Edmund Horner <ejrh00@gmail.com> wrote:
So we'd extend that to:
  - Include in the OR-list "range" subquals of the form (ctid > ? AND
ctid < ?) (either side could be optional, and we have to deal with >=
and <= and having ctid on the rhs, etc.).
  - Cost the range subquals by assuming they don't overlap, and
estimating how many blocks and tuples they span.
  - When beginning the scan, evaluate all the ?s and build an array of
"tid ranges" to fetch.  A tid range is a struct with a starting tid,
and an ending tid, and might just be a single tid item.
  - Sort and remove duplicates.
  - Iterate over the array, using a single fetch for single-item tid
ranges, and starting/ending a heap scan for multi-item tid ranges.

I think I'll try implementing this.

I've set this patch as waiting on author in the commitfest app. 


--
 David Rowley                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services

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

Предыдущее
От: Rajkumar Raghuwanshi
Дата:
Сообщение: Multiple primary key on partition table?
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: pgsql: Improve autovacuum logging for aggressive andanti-wraparound ru