Restoring Backup With OIDs As Primary Key

From: "Ben C" <ben(dot)c(at)ect(dot)com(dot)au>
To: <pgsql-admin(at)postgresql(dot)org>
Subject: Restoring Backup With OIDs As Primary Key
Date: 2008-08-26 03:30:23
Message-ID: 7DA06115D1591D41A33328B737C1F4122F309E@svrect1.ect.local
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hello,

I am trying to restore from a backup db that used oids as primary keys * ... when I do this the max oid value in the new database is around the 1700 mark where as the database I am pulling in is around 20,000,000 . which means any new data added to the dataabse is going to be clobbered.

Is there a way to increment the OID by changing a value in the system tables?

thanks in advance

* at the time this was implemented way back at 7.x, from what I had read it seemed like acceptable practice :/

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Vishal Arora 2008-08-26 04:18:02 Re: Regarding access to a user
Previous Message Alvaro Herrera 2008-08-26 02:34:06 Re: restoring from dump