Re: [HACKERS] Multicolumn hash indexes

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: [HACKERS] Multicolumn hash indexes
Дата
Msg-id CA+TgmoZzMEN3Q0E6Ryn7scR9rtb==ejeRPVExtD776ithp++hw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [HACKERS] Multicolumn hash indexes  (Jesper Pedersen <jesper.pedersen@redhat.com>)
Ответы Re: [HACKERS] Multicolumn hash indexes  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Wed, Sep 27, 2017 at 9:56 AM, Jesper Pedersen
<jesper.pedersen@redhat.com> wrote:
> Maybe an initial proof-of-concept could store the hash of the first column
> (col1) plus the hash of all columns (col1, col2, col3) in the index, and see
> what requirements / design decisions would appear from that.

I thought about that sort of thing yesterday but it's not that simple.
The problem is that the hash code isn't just stored; it's used to
assign tuples to buckets.  If you have two hash codes, you have to
pick one of the other to use for assigning the tuple to a bucket.  And
then if you want to search using the other hash code, you have to
search all of the buckets, which will stink.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

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

Предыдущее
От: Nico Williams
Дата:
Сообщение: Re: [HACKERS] Multicolumn hash indexes
Следующее
От: Emre Hasegeli
Дата:
Сообщение: Re: [HACKERS] [PATCH] Improve geometric types