Re: [HACKERS] inlining SQL functions

2010-04-25 Thread Jim Nasby
On Apr 25, 2010, at 2:13 PM, Tom Lane wrote: > Jim Nasby writes: >> On Apr 2, 2010, at 12:12 PM, Tom Lane wrote: >>> If you're thinking of just replacing the call with a sub-SELECT >>> construct, that's no good in general because it would change the >>> semantics. > >> Since Alexey was working on

Re: [HACKERS] inlining SQL functions

2010-04-25 Thread Tom Lane
Jim Nasby writes: > On Apr 2, 2010, at 12:12 PM, Tom Lane wrote: >> If you're thinking of just replacing the call with a sub-SELECT >> construct, that's no good in general because it would change the >> semantics. > Since Alexey was working on this for us, I'll elaborate. The actual > use case is

Re: [HACKERS] inlining SQL functions

2010-04-25 Thread Jim Nasby
On Apr 2, 2010, at 12:12 PM, Tom Lane wrote: > Alexey Klyukin writes: >> Is there a reason why only a table free SQL functions are allowed to >> be inlined ? I wonder why a simple SQL function containing only a >> SELECT * FROM table can't be expanded inline ? > > If you're thinking of just repl

Re: [HACKERS] inlining SQL functions

2010-04-02 Thread Tom Lane
Alexey Klyukin writes: > Is there a reason why only a table free SQL functions are allowed to > be inlined ? I wonder why a simple SQL function containing only a > SELECT * FROM table can't be expanded inline ? If you're thinking of just replacing the call with a sub-SELECT construct, that's no