Re: non-deterministic error related to MIN/MAX optimization

Поиск
Список
Период
Сортировка
От Jeff Davis
Тема Re: non-deterministic error related to MIN/MAX optimization
Дата
Msg-id 1219772304.6213.238.camel@dell.linuxdev.us.dell.com
обсуждение исходный текст
Ответ на Re: non-deterministic error related to MIN/MAX optimization  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: non-deterministic error related to MIN/MAX optimization  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-bugs
On Tue, 2008-08-26 at 01:04 -0400, Tom Lane wrote:
> Please provide some more detail about those experiments.  The test case
> hasn't been seen to fail in the buildfarm, AFAIR.

Dan Farina, my colleague at Truviso, was experimenting with some query
transformations that pushed the range table entries down into a
subquery.

You can see the effect here:

=> select max(a), generate_series(1,2) as g from foo;
 max | g
-----+---
     | 1
     | 2
(2 rows)

=> -- make "foo" into a subquery and add a no-op
=> -- to prevent it from pulling up the subquery
=> select max(a), generate_series(1,2) as g from (select a as a from foo
offset 0) dummy;
ERROR:  set-valued function called in context that cannot accept a set

So, although Dan's transformations were semantically correct, they ended
up causing this regression failure.

It doesn't have anything to do with the ORDER BY, so that part of my
example was unnecessary.

Regards,
    Jeff Davis

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: BUG #4281: some types of errors do not log statements
Следующее
От: Tom Lane
Дата:
Сообщение: Re: non-deterministic error related to MIN/MAX optimization