Skip site navigation (1) Skip section navigation (2)

Re: inserting new records without OIDs

From: Andreas Pflug <pgadmin(at)pse-consulting(dot)de>
To: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
Cc: mdoggett(at)coas(dot)oregonstate(dot)edu,"[pgADMIN]" <pgadmin-support(at)postgresql(dot)org>
Subject: Re: inserting new records without OIDs
Date: 2004-02-18 10:12:57
Message-ID: 40333AA9.4070605@pse-consulting.de (view raw or flat)
Thread:
Lists: pgadmin-support
Christopher Kings-Lynne wrote:

>> Not true. Currently, you need either OID *or* a primary key. 
>> Obviously, that id column should get a pk.
>> We'll extend the grid some time, to accept any other unique keys 
>> also. Still, defining a PK on every table is best practice.
>> Defining a column as serial does *not* guarantee it's unique!
>
>
> Remember that unique indexes can have multiple NULL values.

Shhh, didn't think of that. So we won't ever accept unique indices for this.

> Also, oids are not guaranteed unique.

AFAICS this only happens on wrap around, i.e. hopefully never. Being 
strict, we shouldn't rely on oid uniqueness, but in practice hopefully 
nobody will ever notice.

Regards,
Andreas



In response to

Responses

pgadmin-support by date

Next:From: Dave PageDate: 2004-02-18 11:11:01
Subject: Re: inserting new records without OIDs
Previous:From: Christopher Kings-LynneDate: 2004-02-18 04:46:47
Subject: Re: inserting new records without OIDs

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group