Re: oid's and primary keys on insert

From: Rob Brown-Bayliss <rob(at)zoism(dot)org>
To: Elaine Lindelef <eel(at)cognitivity(dot)com>
Cc: PostgreSQL General List <pgsql-general(at)postgresql(dot)org>
Subject: Re: oid's and primary keys on insert
Date: 2002-08-09 20:25:33
Message-ID: 1028924732.1856.36.camel@everglade.zoism.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sat, 2002-08-10 at 08:13, Elaine Lindelef wrote:

> Add another column of type SERIAL and use it to store a plain
> incremented integer, and use it like you used to use OIDs.

Except that this brings me back to the reason for not useing a sequence
as a primary key:

What happens when site2 has already placed a row with value 1234 in this
column and site1's sequence is up to 1233, I insert the row, and now I
have two rows with 1234 as the ID row...

At least OID's will be unique as when inserting rows from another site
they still use the OID from the local machine.

--

*
* Rob Brown-Bayliss
*

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Rob Brown-Bayliss 2002-08-09 20:32:39 Re: oid's and primary keys on insert
Previous Message Joe Conway 2002-08-09 20:22:34 Re: oid's and primary keys on insert