Re: BUG #4656: Indexes not used when comparing nextval() and currval() to integers - Mailing list pgsql-bugs

From Heikki Linnakangas
Subject Re: BUG #4656: Indexes not used when comparing nextval() and currval() to integers
Date
Msg-id 49993D6D.3020504@enterprisedb.com
Whole thread Raw
In response to BUG #4656: Indexes not used when comparing nextval() and currval() to integers  ("Mathias Seiler" <mathias.seiler@gmail.com>)
List pgsql-bugs
toruvinn wrote:
> On Mon, 16 Feb 2009 10:37:27 +0100, Heikki Linnakangas
> <heikki.linnakangas@enterprisedb.com> wrote:
>> You can read the value returned by currval into a host language
>> variable and send it back as a ?.
> Wouldn't it be possible to do UPDATE booking_entries SET date = ? where
> id = (SELECT currval('booking_entries_id_seq'::regclass)); too?

Oh yes, that should work as well.

--
   Heikki Linnakangas
   EnterpriseDB   http://www.enterprisedb.com

pgsql-bugs by date:

Previous
From: "Brundle Fly"
Date:
Subject: BUG #4658: copy problem
Next
From: "Tomasz Kolaj"
Date:
Subject: BUG #4659: Can't configure static postgresql with static openssl