Re: BUG #1252: Optimization of SELECT for NOT NULL case

Поиск
Список
Период
Сортировка
От Bruno Wolff III
Тема Re: BUG #1252: Optimization of SELECT for NOT NULL case
Дата
Msg-id 20040915172154.GA28610@wolff.to
обсуждение исходный текст
Ответ на BUG #1252: Optimization of SELECT for NOT NULL case  ("PostgreSQL Bugs List" <pgsql-bugs@postgresql.org>)
Ответы Re: BUG #1252: Optimization of SELECT for NOT NULL case  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: BUG #1252: Optimization of SELECT for NOT NULL case  ("Alexander Kirpa" <postgres@bilteks.com>)
Список pgsql-bugs
On Tue, Sep 14, 2004 at 00:57:07 +0100,
  PostgreSQL Bugs List <pgsql-bugs@postgresql.org> wrote:
>
> Description:        Optimization of SELECT for NOT NULL case
>
> Details:
>
> CREATE TABLE x (id int4 NOT NULL);
> Populate table, for instance, 10M rows;
> SELECT count(*) from x WHERE x IS NULL;
> Optimizator should rewrite "x IS NULL" to simple "false"

Based on responses to other optimization requests I have seen, I think the
answer to this one is going to be that it isn't worth paying the cost
for every query to check for this case, since no one is going to write
a query like this except by mistake.

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: character and text comparison
Следующее
От: Jacek Rembisz
Дата:
Сообщение: Re: character and text comparison