Re: [Re: PRIMARY KEY]

From: Phillip Smith <phillip(dot)smith(at)weatherbeeta(dot)com(dot)au>
To: Bruno Wolff III <bruno(at)wolff(dot)to>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: [Re: PRIMARY KEY]
Date: 2007-03-09 22:44:49
Message-ID: 1173480289.4925.77.camel@phillip-desktop
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Of course - my bad... That's the main reason I upgraded to 8.2!

On Fri, 2007-03-09 at 09:03 -0600, Bruno Wolff III wrote:

> On Wed, Mar 07, 2007 at 23:20:12 +1100,
> Phillip Smith <fukawi2(at)iinet(dot)net(dot)au> wrote:
> > If you actually need to know the value of N_GEN in your ASP application,
> > you will need to query the database first and select the NEXTVAL from
> > the sequence that the "serial" data type will create, then use that
> > returned value in your insert - ie, DON'T exclude it from the insert,
> > otherwise it will default to NEXTVAL again and return a different value.
>
> In 8.2, you can also use the RETURNING clause to get those values.

*******************Confidentiality and Privilege Notice*******************

The material contained in this message is privileged and confidential to
the addressee. If you are not the addressee indicated in this message or
responsible for delivery of the message to such person, you may not copy
or deliver this message to anyone, and you should destroy it and kindly
notify the sender by reply email.

Information in this message that does not relate to the official business
of Weatherbeeta must be treated as neither given nor endorsed by Weatherbeeta.
Weatherbeeta, its employees, contractors or associates shall not be liable
for direct, indirect or consequential loss arising from transmission of this
message or any attachments

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Jeff Davis 2007-03-10 01:16:13 Re: Statistics
Previous Message gherzig 2007-03-09 20:35:11 Re: index not being used. Why?