pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Marion McKelvie <marion@streamlet.co.uk>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-admin@postgresql.org
Subject: Re: restoring large objects
Date: Tue, 6 Apr 2004 16:46:11 +0100
Message-ID: <MPEMKONPODHGLICHEKEGCEIOCOAA.marion@streamlet.co.uk> (raw)
In-Reply-To: <25098.1081265566@sss.pgh.pa.us>

Tom

Many thanks - you're right, the references are stored (by the application
using the database) in a column of type text.  That presumably means the
only way I can get a reliably restorable dump is by writing something
myself... or adding an extra duplicate column which is of type oid... or
something which somehow tracks the old and new ids... an interesting
challenge!

Regards,

Marion

-----Original Message-----
From: Tom Lane [mailto:tgl@sss.pgh.pa.us]
Sent: 06 April 2004 16:33
To: Marion McKelvie
Cc: pgsql-admin@postgresql.org
Subject: Re: [ADMIN] restoring large objects


"Marion McKelvie" <marion@streamlet.co.uk> writes:
> I am running with 7.1.2 (I know it's old, but I don't have a lot of choice
> given the application running on it), and have dumped the database with
> the -b option.  However, the restoration process generates new ids for the
> large objects which means the link between the data table referencing them
> and the content of pg_largeobject is lost.

pg_dump includes code in the dump that is supposed to update references
to match the new large object OIDs.  Check into why that didn't work
for you.  (One fairly likely possibility is that you stored the
references in the wrong type of column --- it has to be type "oid" or
"lo" or pg_dump won't think it needs updating.)

			regards, tom lane




view thread (6+ messages)  latest in thread

Message-ID: <MPEMKONPODHGLICHEKEGCEIOCOAA.marion@streamlet.co.uk>
Permalink:  ../MPEMKONPODHGLICHEKEGCEIOCOAA.marion@streamlet.co.uk/
Also on:    postgresql.org/message-id/MPEMKONPODHGLICHEKEGCEIOCOAA.marion@streamlet.co.uk

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: marion@streamlet.co.uk, tgl@sss.pgh.pa.us
  Subject: Re: restoring large objects
  In-Reply-To: <MPEMKONPODHGLICHEKEGCEIOCOAA.marion@streamlet.co.uk>
  References: <25098.1081265566@sss.pgh.pa.us> <MPEMKONPODHGLICHEKEGCEIOCOAA.marion@streamlet.co.uk>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox