Обсуждение: Bug #910: query with inherits

Поиск
Список
Период
Сортировка

Bug #910: query with inherits

От
pgsql-bugs@postgresql.org
Дата:
Igor (programer_c@land.ru) reports a bug with a severity of 4
The lower the number the more severe it is.

Short Description
query with inherits

Long Description
In the next situation:
       CREATE TABLE main (f1 int4 NOT NULL, PRIMARY KEY(f1));
       CREATE TABLE derived (f2 int4) INHERIT (main);
       CREATE TABLE other (f3 int4, f1 int1 NOT NULL);
expression
       explain analyze SELECT * FROM main WHERE f1=1;
executed by index scan main and derived,
but expression
       explain analyze SELECT * FROM main m, other o WHERE o.f3=1 AND o.f1=m.f1;
executed by seq scan main and derived. Why?

                                           Best regard with Russia!

Sample Code


No file was uploaded with this report