Re: Re: Functions returning sets

From: Hannu Krosing <hannu(at)tm(dot)ee>
To: mlw <markw(at)mohawksoft(dot)com>
Cc: Stephan Szabo <sszabo(at)megazone23(dot)bigpanda(dot)com>, Hackers List <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Re: Functions returning sets
Date: 2001-05-20 07:34:31
Message-ID: 3B077387.4EFD6BF9@tm.ee
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

mlw wrote:
>
> Stephan Szabo wrote:
> >
> > (Machine couldn't find mx record for mohawksoft, replying only
> > to list)
> >
> > On Sat, 19 May 2001, mlw wrote:
> >
> > > Sorry to gripe here. Don't get me wrong, I think Postgres is amazing, and I
> > > think all you guys do an amazing job.
> > >
> > > Is it just me, or do others agree, functions returning sets need to be able to
> > > be used in a select where equal clause.
> > >
> > > select * from table where field = funct_set('bla bla');
>
> I don't understand your reasoning. Look at the syntax:
>
> select * from foo where bar = function(...);
>
> If function() returns one value, then only one will be returned and the
> relation features of postgres can be used, as in "select * from foo, this where
> foo.bar = function() and foo.bar = this.that"
>
> If function() can return multiple values, should it not follow that multiple
> values should be selected?

of course not! if function() can return (i.e. returns) as set then bar
must be of
type SET too and only rows that are = (in whatever sense currently
defined) should
be returned

---------------
Hannu

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jean-Michel POURE 2001-05-20 07:46:03 Re: Need Postgresql ODBC Driver
Previous Message mordicus 2001-05-20 07:32:33 RE: Re: Functions returning sets