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

Re: pg_restore problem

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: jules(dot)alberts(at)arbodienst-limburg(dot)nl
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: pg_restore problem
Date: 2002-08-15 15:45:57
Message-ID: 23742.1029426357@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-novice
"Jules Alberts" <jules(dot)alberts(at)arbodienst-limburg(dot)nl> writes:
> Sorry, I wasn't quite clear. The problem isn't that the references get 
> lost, but that the actual OIDs of the blobs change.

Yes, they will, and there's not anything you can do to prevent it.
What is supposed to happen is that pg_restore should update your
CUST_BLOBS table to contain new blob OIDs instead of old ones.
It builds a map from the old OIDs, which it can see in the dump file,
to the new ones that get assigned on-the-fly as the blobs are loaded.
Then it looks through the database for OID columns, and substitutes
new blob OIDs wherever it can find a match to the list of old OIDs.

One hole in this approach is that the lookup table CUST_BLOBS had better
be present when the blob loading is done.  Perhaps you tried to load it
separately after loading the blobs?

			regards, tom lane

In response to

Responses

pgsql-novice by date

Next:From: Chad ThompsonDate: 2002-08-15 17:41:30
Subject: BLOBs
Previous:From: Gabriel Menini [F.I.S.]Date: 2002-08-15 15:28:40
Subject: Accessing thru webmin, don't have admin password

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