Re: Re: Patch to add functionality to specify ORDER BY in CREATE FUNCTION for SRFs - Mailing list pgsql-hackers

From David Johnston
Subject Re: Re: Patch to add functionality to specify ORDER BY in CREATE FUNCTION for SRFs
Date
Msg-id CAKFQuwZVz14tgSd9qBX4bqkhvSUEyGgbn3WDdGdCZQAUuaEzhQ@mail.gmail.com
Whole thread Raw
In response to Re: Re: Patch to add functionality to specify ORDER BY in CREATE FUNCTION for SRFs  (Jim Nasby <Jim.Nasby@BlueTreble.com>)
List pgsql-hackers
On Tue, Jan 6, 2015 at 4:15 PM, Jim Nasby <Jim.Nasby@bluetreble.com> wrote:
On 1/6/15, 10:32 AM, Alvaro Herrera wrote:
Tom Lane wrote:

What would make sense to me is to teach the planner about inlining
SQL functions that include ORDER BY clauses, so that the performance
issue of a double sort could be avoided entirely transparently to
the user.

Wouldn't this be applicable to functions in other languages too, not
only SQL?

Dumb question... we can inline functions from other languages? What chunk of code handles that?

​We cannot that I know of.  The point being made here is that suggesting an alternative that requires inlining ​doesn't cover the entire purpose of this feature since the feature can be applied to functions that cannot be inlined.

David J.

pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: pg_rewind in contrib
Next
From: Josh Berkus
Date:
Subject: Re: Turning recovery.conf into GUCs