Re: Convert coalesce to or/and - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Convert coalesce to or/and
Date
Msg-id 4125586.1767307866@sss.pgh.pa.us
Whole thread Raw
In response to Convert coalesce to or/and  (Nicolas Adenis-Lamarre <nicolas.adenis.lamarre@gmail.com>)
List pgsql-hackers
Nicolas Adenis-Lamarre <nicolas.adenis.lamarre@gmail.com> writes:
> would it be accepted to do a patch to replace coalesce by and/or,
> mainly to fix related estimations.

Almost certainly not.  It'd be very hard to do that while preserving
the expected semantics of COALESCE: no argument is to be evaluated
more than once, and people sometimes expect strict left-to-right
evaluation.  I've even seen it used as an intentional optimization
fence.

If you think you can improve the estimation around it, I'd suggest
tackling that directly.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Nicolas Adenis-Lamarre
Date:
Subject: Convert coalesce to or/and
Next
From: Alexander Korotkov
Date:
Subject: Re: Implement waiting for wal lsn replay: reloaded