Re: Problem running or executing a function in Postgresql - Mailing list pgsql-general

From Michael Fuhr
Subject Re: Problem running or executing a function in Postgresql
Date
Msg-id 20050901101053.GA26810@winnie.fuhr.org
Whole thread Raw
In response to Problem running or executing a function in Postgresql  ("Venki" <Venki@insoft.com>)
List pgsql-general
On Thu, Sep 01, 2005 at 11:58:27AM +0530, Venki wrote:
>
> new_id = EXECUTE("SELECT FROM currval("mydata_id_seq")");

The above line has quoting problems and an erroneous SELECT query,
and it wouldn't work anyway because that's not the way to retrieve
results from EXECUTE.  Aside from that, EXECUTE isn't necessary in
this case.  Try this:

new_id := currval(''mydata_id_seq'');

--
Michael Fuhr

pgsql-general by date:

Previous
From: Richard Huxton
Date:
Subject: Re: Problem running or executing a function in Postgresql
Next
From: Richard Huxton
Date:
Subject: Re: syslog message I do not understand