Re: Insert may fail if i create a primary key on the oid - Mailing list pgsql-general

From Richard Huxton
Subject Re: Insert may fail if i create a primary key on the oid
Date
Msg-id 41A473BD.5010708@archonet.com
Whole thread Raw
In response to Insert may fail if i create a primary key on the oid column?  ("songsubo" <songsubo@163.com>)
List pgsql-general
songsubo wrote:
> I create a primary key on the "oid" column. The oid is generate by
> system itself. The oid may overlap, when this happen, this operation
> may fail?

Yes. If you want a self-incrementing primary key, why not use a SERIAL type?

--
  Richard Huxton
  Archonet Ltd

pgsql-general by date:

Previous
From: "Net Virtual Mailing Lists"
Date:
Subject: Re: Creating index on a view?
Next
From: Francis Reed
Date:
Subject: Moving/Using Postgres Binaries on multiple machines