Re: OID and PK/FK KEYS

From: Kevin Barnard <kevin(dot)barnard(at)gmail(dot)com>
To: Raffaele Spizzuoco <kilomegabyte(at)freemail(dot)it>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: OID and PK/FK KEYS
Date: 2004-10-20 20:59:29
Message-ID: b068057c041020135920697ae@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

A better solution is to use the serial data type. OID is depreciated
and may go away.

http://www.postgresql.org/docs/7.4/static/datatype.html#DATATYPE-SERIAL

On 19 Oct 2004 07:54:36 -0700, Raffaele Spizzuoco
<kilomegabyte(at)freemail(dot)it> wrote:
> Hi!
>
> I'm from Italy, and sorry about my english...
> I have a question that I know it is already said in the groups but I
> have however some doubts
> I have seen it is technically possible to use OID as PRIMARY KEY and
> as FOREIGN KEY but it is correct to do so for the database's logical
> integrity?
> Is it better I use in any case other keys and not oid to avoid the
> possible wraparound? or the wraparound is an extreme case and so I can
> use quietly OID as PRIMARY and FOREIGN KEY?
>
> Thanks
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Gary Doades 2004-10-20 22:43:54 Re: how much ram do i give postgres?
Previous Message Thomas F.O'Connell 2004-10-20 20:40:22 CREATE TEMPORARY TABLE AS ... ON COMMIT?