On Thu, 03 Apr 2008 10:33:56 -0400
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Gregory Stark <stark(at)enterprisedb(dot)com> writes:
> > You could fix that more cleanly with "ALTER FUNCTION myfunction
> > ROWS 1" but only if that's always true, not just for
> > myfunction(3,5).
>
> Perhaps the function shouldn't be declared SETOF in the first place?
Does I have to take it as:
if it is not declared as SETOF all optimisation and planning marvels
will happen without I add LIMIT 1?
What about queries?
Is it an information that is used for anything else other than
stopping earlier?
Summarising it up: is it worth to add it here and there as an
optimisation flag?
thanks
--
Ivan Sergio Borgonovo
http://www.webthatworks.it