Re: [HACKERS] Strict Set Returning Functions

2011-06-15 Thread Simon Riggs
On Thu, Jun 16, 2011 at 12:24 AM, Tom Lane wrote: > Simon Riggs writes: >> On Wed, Jun 15, 2011 at 8:05 PM, Tom Lane wrote: >>> Simon Riggs writes: So a function that is both STRICT and SET RETURNING will return rows. > >>> Really?  The case behaves as expected for me. > >> Seems that's th

Re: [HACKERS] Strict Set Returning Functions

2011-06-15 Thread Tom Lane
Simon Riggs writes: > On Wed, Jun 15, 2011 at 8:05 PM, Tom Lane wrote: >> Simon Riggs writes: >>> So a function that is both STRICT and SET RETURNING will return rows. >> Really? The case behaves as expected for me. > Seems that's the wrong question. Let me return to why I raised this: > Why

Re: [HACKERS] Strict Set Returning Functions

2011-06-15 Thread Simon Riggs
On Wed, Jun 15, 2011 at 8:05 PM, Tom Lane wrote: > Simon Riggs writes: >> STRICT functions return NULL if any of their inputs are NULL according >> to the manual, so that they need not be executed at all. > >> Unless it is a Set Returning Function, in which case a NULL input is >> not reduced nor

Re: [HACKERS] Strict Set Returning Functions

2011-06-15 Thread Tom Lane
Simon Riggs writes: > STRICT functions return NULL if any of their inputs are NULL according > to the manual, so that they need not be executed at all. > Unless it is a Set Returning Function, in which case a NULL input is > not reduced nor does it to appear to be handled as a special case in > t

[HACKERS] Strict Set Returning Functions

2011-06-15 Thread Simon Riggs
STRICT functions return NULL if any of their inputs are NULL according to the manual, so that they need not be executed at all. Unless it is a Set Returning Function, in which case a NULL input is not reduced nor does it to appear to be handled as a special case in the executor function scan code.