Re: Inlining of functions (doing LIKE on an array) - Mailing list pgsql-performance

From Tom Lane
Subject Re: Inlining of functions (doing LIKE on an array)
Date
Msg-id 2795.1478980772@sss.pgh.pa.us
Whole thread Raw
In response to Re: Inlining of functions (doing LIKE on an array)  ("ldh@laurent-hasson.com" <ldh@laurent-hasson.com>)
Responses Re: Inlining of functions (doing LIKE on an array)  ("ldh@laurent-hasson.com" <ldh@laurent-hasson.com>)
List pgsql-performance
"ldh@laurent-hasson.com" <ldh@laurent-hasson.com> writes:
> I wish there were a way to force inlining, or some other mechanism as the performance difference is large here. I'll
beusing the inlining approach when possible, but the SQL Function approach is simpler and will likely be more suitable
forsome developers. 

I'm not sure that there's any fundamental reason why we don't inline SQL
functions containing sub-selects.  It may just be not having wanted to put
any effort into the case way-back-when.  Inlining happens too late to
allow a resulting WHERE EXISTS to get mutated into a semijoin, but in this
example that couldn't happen anyway, so it's not much of an objection.

            regards, tom lane


pgsql-performance by date:

Previous
From: Jeff Janes
Date:
Subject: Re: Any advice tuning this query ?
Next
From: "ldh@laurent-hasson.com"
Date:
Subject: Re: Inlining of functions (doing LIKE on an array)