Re: Downgrading v8.4 database to v8.3

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Greg Smith <greg(at)2ndquadrant(dot)com>
Cc: Jason Tan Boon Teck <tanboonteck(at)gmail(dot)com>, pgsql-admin(at)postgresql(dot)org
Subject: Re: Downgrading v8.4 database to v8.3
Date: 2010-05-05 16:13:24
Message-ID: 3377.1273076004@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Greg Smith <greg(at)2ndquadrant(dot)com> writes:
> Jason Tan Boon Teck wrote:
>> I need to move some databases written in Psql v8.4 to the stable
>> production server running v8.3. I tried pg_dump and pg_restore as well
>> as PgAdmin3. I am unable to do so due to the backward
>> incompatibility. Is there anyway to do this?

> You can try connecting a 8.3 client to the 8.4 server, then running
> pg_dump from that 8.3 client. That's a common approach for
> dump/restore when moving forward a version, and it may resolve your
> issue when moving backward one too. The 8.3 client shouldn't dump
> anything the 8.3 server doesn't know how to restore.

That's very likely to fail, and worse to do so silently, because 8.3
pg_dump doesn't know what's different about 8.4 system catalogs.

I think your only real recourse in this situation is to do a plain dump
from the 8.4 server (with 8.4 pg_dump) and then manually edit the dump
script to remove any 8.4-only syntax. If your application isn't actually
using any 8.4-only features this should be a pretty trivial matter.
If it is, then of course you have some work to do.

regards, tom lane

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Jason Tan Boon Teck 2010-05-05 16:25:35 Re: Downgrading v8.4 database to v8.3
Previous Message Iñigo Martinez Lasala 2010-05-05 16:09:00 Re: Downgrading v8.4 database to v8.3