On Tue, Apr 19, 2005 at 09:34:43 +0200, KÖPFERL Robert <robert.koepferl@sonorys.at> wrote:
> That was a nice answer - rather compleete.
>
> However at least I am questioning myself for a long time about what happens
> if one does a select from a SRF. The function may return millions of records
> (i.e. select * from x where a>1). Is this data streamed through the query
> process or does postgres create a temporary table.
>
> An "explain select * from srf()" just returns a function invocation. :-/
> How does this work?
If the function isn't written using a language of SQL, it isn't going to
optimize well when you only want to see part of the table.