From: | Darren Ferguson <darren(at)crystalballinc(dot)com> |
---|---|
To: | Wojciech Strza³ka <wojtek_strzalka(at)interia(dot)pl> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: PL/pgSQL |
Date: | 2002-10-04 13:29:59 |
Message-ID: | Pine.LNX.4.44.0210040928230.4231-100000@thread.crystalballinc.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Try
EXECUTE ''SELECT MAX(''||column||'') INTO lp FROM '' || table;
This should work but haven't tested it.
Normally with select into though is is
select foo into bar from aa where id = _id;
HTH
On Thu, 3 Oct 2002, Wojciech Strza³ka wrote:
> i've got a simple plsql function and this line is wrong:
>
> EXECUTE ''SELECT INTO lp MAX('' || column || '') AS MX FROM '' || table
> || '';'';
>
> with error message:
>
> "parse error at or near 'INTO' "
>
> it seems like it don't recognize SELECT INTO - but what's wrong?
>
> Thaks, Wojtek
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/users-lounge/docs/faq.html
>
--
Darren Ferguson
From | Date | Subject | |
---|---|---|---|
Next Message | Vilson farias | 2002-10-04 13:52:40 | Re: Postgres for Windows |
Previous Message | Richard Huxton | 2002-10-04 13:29:51 | Re: Query optimization |