Received: from magus.postgresql.org (magus.postgresql.org [87.238.57.229]) by mail.postgresql.org (Postfix) with ESMTP id 4B5511931E6E for ; Wed, 11 Jul 2012 00:41:24 -0300 (ADT) Received: from mail-yx0-f174.google.com ([209.85.213.174]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1Sonnl-0003CQ-Iw for pgsql-sql@postgresql.org; Wed, 11 Jul 2012 03:41:23 +0000 Received: by yenl2 with SMTP id l2so789270yen.19 for ; Tue, 10 Jul 2012 20:41:07 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:x-gm-message-state; bh=pUn8zwPTDT60ajfxNRj+8qhtyL1mZxoObejST1CbL5M=; b=OsNkFzjYr5gWtW4UyEJB/oP6NcgxOM4gNgJT0Q25swmKYF54FpcdSzzXyFs/cYP92L MsWJyNH/6AcDkEfR/4FEP76/2YuV2KcvZTaYHZLK8xfCQs9hTYQCC//Udyy20rD5/2Iy tapJrpUiAyH9HL1lk6N/GD1eBLAQfmhWXmh+bAXHPADNZ9wZPxm2W+ZBX8aZXpNcl+4P Nche4mt91i4zkoOQPGCkgryNVXaftw20KaAZLC6GOqqgk0UKoq3RLhO/qTI1PY3r/Jc4 idjvyIKKK3g5rWmsmmlAiupaxdvySS5O0J4b+zMQkVu3qGIz8d+2LZDUDl6D6ScK6ALv nh8A== Received: by 10.66.89.170 with SMTP id bp10mr78259117pab.12.1341978067297; Tue, 10 Jul 2012 20:41:07 -0700 (PDT) Received: from ayaki.localdomain (office1.postnewspapers.com.au. [150.101.171.128]) by mx.google.com with ESMTPS id pi7sm802750pbb.56.2012.07.10.20.41.04 (version=SSLv3 cipher=OTHER); Tue, 10 Jul 2012 20:41:06 -0700 (PDT) Message-ID: <4FFCF5CD.8080100@ringerc.id.au> Date: Wed, 11 Jul 2012 11:41:01 +0800 From: Craig Ringer User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20120605 Thunderbird/13.0 MIME-Version: 1.0 To: Chris Preston CC: pgsql-sql@postgresql.org Subject: Re: Simple Upgrade from PostgreSQL version 8.1.11 (With schemas) References: <4FEE0DCB.8020503@gmail.com> <3EED475E754849429C74FCAB58B57CFF@chrisp> In-Reply-To: <3EED475E754849429C74FCAB58B57CFF@chrisp> Content-Type: multipart/alternative; boundary="------------010904010200000707020805" X-Gm-Message-State: ALoCoQmfibTLGgsM4vIBPNUaM1BFT/bEsf/KuGFgA+eksJw6ab3NODCWo0Kz4ifKKG5KU4lNeEYQ X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201207/4 X-Sequence-Number: 36741 This is a multi-part message in MIME format. --------------010904010200000707020805 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On 07/10/2012 11:28 PM, Chris Preston wrote: > Hello all, > How far can I get to a higher version of PostgreSQL by just entering a > command line instruction to upgrade without any major effort? Not very, unless your database and queries are very simple. At minimum you'll have to deal with the removal of implicit casts to text ( http://www.postgresql.org/docs/current/static/release-8-3.html#AEN116407) and, if you use bytea, the change of default bytea format ( http://www.postgresql.org/docs/current/static/release-9-0.html#AEN109764). In general, you will want to read the "Migration to" notes for each version: http://www.postgresql.org/docs/current/static/release-8-2.html http://www.postgresql.org/docs/current/static/release-8-3.html http://www.postgresql.org/docs/current/static/release-8-4.html http://www.postgresql.org/docs/current/static/release-9-0.html http://www.postgresql.org/docs/current/static/release-9-1.html Alternately, you could try using PostgreSQL 9.1's pg_dump on your 8.1 database, load the dump into a 9.1 instance, run your client against it and see what breaks. For simpler apps that can be a reasonable choice. -- Craig Ringer --------------010904010200000707020805 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit
On 07/10/2012 11:28 PM, Chris Preston wrote:
Hello all,
How far can I get to a higher version of PostgreSQL by just entering a
command line instruction to upgrade without any major effort?

Not very, unless your database and queries are very simple.

At minimum you'll have to deal with the removal of implicit casts to text ( http://www.postgresql.org/docs/current/static/release-8-3.html#AEN116407) and, if you use bytea, the change of default bytea format ( http://www.postgresql.org/docs/current/static/release-9-0.html#AEN109764).

In general, you will want to read the "Migration to" notes for each version:

http://www.postgresql.org/docs/current/static/release-8-2.html
http://www.postgresql.org/docs/current/static/release-8-3.html
http://www.postgresql.org/docs/current/static/release-8-4.html
http://www.postgresql.org/docs/current/static/release-9-0.html
http://www.postgresql.org/docs/current/static/release-9-1.html

Alternately, you could try using PostgreSQL 9.1's pg_dump on your 8.1 database, load the dump into a 9.1 instance, run your client against it and see what breaks. For simpler apps that can be a reasonable choice.

--
Craig Ringer
--------------010904010200000707020805--