Re: SELECT results in "ERROR: index key does not match expected index column"

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: SELECT results in "ERROR: index key does not match expected index column"
Дата
Msg-id CA+hUKGJPdWgC1pY5EmDv8z71VKwNXN9cz_2Lk=6TX_hjzbh_vw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: SELECT results in "ERROR: index key does not match expected index column"  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
On Wed, Jul 3, 2019 at 10:50 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Manuel Rigger <rigger.manuel@gmail.com> writes:
> > Consider the following test case:
>
> > CREATE TABLE t0(c0 boolean UNIQUE);
> > CREATE INDEX i0 ON t0((nullif(FALSE, TRUE)));
> > INSERT INTO t0(c0) VALUES(TRUE);
> > SELECT * FROM t0 WHERE nullif(FALSE, TRUE) OR t0.c0;
> > ERROR:  index key does not match expected index column
>
> Huh.  I don't see that in HEAD/v12, but it does reproduce in v11
> and quite a large number of branches before that.  Looking ...

Git bisect points to this commit as the one that fixed the problem:

commit 1a8d5afb0dfc5d0dcc6eda0656a34cb1f0cf0bdf
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date:   Sat Feb 9 17:30:43 2019 -0500

    Refactor the representation of indexable clauses in IndexPaths.

-- 
Thomas Munro
https://enterprisedb.com



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

Предыдущее
От: Gavin Flower
Дата:
Сообщение: Re: SELECT results in "ERROR: index key does not match expected indexcolumn"
Следующее
От: Tom Lane
Дата:
Сообщение: Re: SELECT results in "ERROR: index key does not match expected index column"