Re: Unexplained SQL behavior

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Unexplained SQL behavior
Дата
Msg-id 7208.1029635724@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Unexplained SQL behavior  ("JOE" <joe@piscitella.com>)
Список pgsql-sql
"JOE" <joe@piscitella.com> writes:
> In the examples below I have a view with 10 columns.  I run an explain plan=
>  and it uses the primary key of the driver table (enrollment table) as to b=
> e expected and executes in 1.86 msec.  When I added another columns (and it=
>  is a null value casted to a timestamp - LASTACCESSED) the execution plan n=
> ow uses a totally different plan and now runs for 8622.16 msec.  Anyone hav=
> e any ideas or explination that may help understand??  --- thanks

Seems odd to me too, but it's difficult to speculate without being able
to try to reproduce the example.  Could we see the full declarations of
the tables involved?  (pg_dump -s output would be good.)
        regards, tom lane


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

Предыдущее
От: "JOE"
Дата:
Сообщение: Unexplained SQL behavior
Следующее
От: "Julian Scarfe"
Дата:
Сообщение: Ordering with GROUPs