Re: pg_dump With OIDs Supported?

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Dylan Hansen <dhansen(at)pixpo(dot)com>
Cc: pgsql-general(at)postgresql(dot)org, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Subject: Re: pg_dump With OIDs Supported?
Date: 2006-06-23 18:17:43
Message-ID: 17298.1151086663@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Dylan Hansen <dhansen(at)pixpo(dot)com> writes:
> Since we've started using the pg_autovacuum table we've come to
> realize that keeping OID values between our database dumps is
> critical. I've been doing some testing using the pg_dump command
> with the --oids option.

--oids is only meant to preserve OIDs within user tables; it never has
and never will preserve OIDs for system-catalog entries. The real
problem here is pg_autovacuum, which doesn't have any dump/restore
support at the moment. This is because we stuck it into 8.1 at the last
minute and aren't yet convinced it will survive in its current form.

It strikes me that a relatively trivial hack would make it easier to
dump and restore pg_autovacuum manually using COPY: change the declared
type of the vacrelid column to "regclass". This would make no
difference to the internal use of the table, but it'd cause COPY to emit
the column values in a symbolic format that would restore correctly.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Wes 2006-06-23 18:29:09 Re: Adding foreign key constraints without integrity
Previous Message TJ O'Donnell 2006-06-23 18:14:15 Re: Changing encoding of a database