Re: [GENERAL] Problems with Set Returning Functions (SRFs)

From: "Otto Blomqvist" <o(dot)blomqvist(at)secomintl(dot)com>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: [GENERAL] Problems with Set Returning Functions (SRFs)
Date: 2005-04-06 22:31:45
Message-ID: d31o0l$slu$1@news.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-sql

Ofcourse this works perfectly !

Thanks a lot Tom !

Just curious, is this (x)-"trick" in the postgres manual somewhere ? Just
just common SQL guru knowledge ? ;)

/Otto Blomqvist

"Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote in message
news:5852(dot)1112819444(at)sss(dot)pgh(dot)pa(dot)us(dot)(dot)(dot)
> "Otto Blomqvist" <o(dot)blomqvist(at)secomintl(dot)com> writes:
> > secom=# select f1, f2, f3 from testpassbyval(1, (Select number1 from
test));
> > ERROR: more than one row returned by a subquery used as an expression
>
> In 8.0 I think it'd work to do
>
> select (x).f1, (x).f2, (x).f3 from
> (select testpassbyval(1, number1) as x from test) ss;
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 7: don't forget to increase your free space map settings
>

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message David Parker 2005-04-06 22:37:33 Re: monitoring database activity on solaris
Previous Message Tom Lane 2005-04-06 22:27:01 Re: Big trouble with memory !!

Browse pgsql-sql by date

  From Date Subject
Next Message TJ O'Donnell 2005-04-07 03:48:23 9.17.5. Row-wise Comparison
Previous Message Tom Lane 2005-04-06 20:30:44 Re: Problems with Set Returning Functions (SRFs)