Dennis Bjorklund <db@zigo.dhs.org> writes:
> Is
> SELECT 42, srf();
> the same as
> SELECT 42, * FROM srf();
> ?
No.
> In my view the first version is an error. It's not like you can put a
> normal table in the select list, so why can we put a set returning
> function there? Ie, is it really a feature?
To some extent it's a hangover from PostQUEL ... but there are things
you can do with it that you can't currently do with SRFs in FROM.
See for instance the "listchildren" example in the manual:
http://www.postgresql.org/docs/8.0/static/xfunc-sql.html#AEN29503
regards, tom lane