Search Postgresql Archives

Re: Bug? Function with side effects not evaluated in CTE

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 18, 2013 at 8:37 PM, David Johnston <polobo@xxxxxxxxx> wrote:
> Merlin Moncure-2 wrote
>> Regardless, the point at hand is whether specific plan semantics down
>> the chain can control whether or not volatile expressions should run.
>> Clearly, at least to me, they should not.
>
> Put differently ideally this should be put either on the todo list or the
> "we do not want" list and further inquiries can then go to building up
> enough popular demand to convince someone to implement it.  Maybe there
> should be a "convince us" list? Not a todo yet but something still be
> considered.

I would vote it as todo.

> Keeping in mind that there are likely volatile queries relying on the
> current optimization that would become non-optimized and possibly very
> poorly performing.  Since the "fix" for these would be a simple alter
> function to make them stable the cost benefit seems worthwhile - since those
> functions are probably mis-identified in the first place due to the use of
> the default.

Any reliance on that behavior would be wrong because it's expressly
contraindicated by the documentation.  TBH, If it were not
specifically documented that way, I would be considering this to be
bugged behavior.  As for function mis-identification, fair point, but
that's a general problem and not specifically related to CTE
evaluation.

merlin


-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux