X-Original-To: pgsql-admin@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 4F31E474E61 for ; Thu, 20 Feb 2003 05:43:41 -0500 (EST) Received: from postgresql.org ([64.49.215.8]) by localhost (postgresql.org [64.49.215.8:10024]) (amavisd-new) with SMTP id 39040-06 for ; Thu, 20 Feb 2003 05:43:30 -0500 (EST) Received: from gsy_sbs_1.cisx.com (unknown [213.133.202.58]) by postgresql.org (Postfix) with ESMTP id 28532475ADE for ; Thu, 20 Feb 2003 05:42:05 -0500 (EST) Received: from DEMOLITION ([192.168.100.22]) by gsy_sbs_1.cisx.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2650.21) id FJ1J93YC; Thu, 20 Feb 2003 10:34:55 -0000 Message-ID: <003401c2d8cd$48fcaf50$1664a8c0@DEMOLITION> From: "Donald Fraser" To: "[ADMIN]" References: <20030219112211.K36237-100000@megazone23.bigpanda.com> Subject: Re: pg_dumpall Date: Thu, 20 Feb 2003 10:46:03 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 X-Virus-Scanned: by amavisd-new X-Archive-Number: 200302/328 X-Sequence-Number: 7526 > On Wed, 19 Feb 2003, Donald Fraser wrote: > > > PostgreSQL 7.3.1 on i686-pc-linux-gnu, compiled by GCC 2.96 > > > > I issue the following command: > > CREATE DATABASE "CISX" WITH OWNER = postgres TEMPLATE = template1 ENCODING = 'SQL_ASCII'; > > > > When I do a backup from the database using pg_dumpall (with no command line options) it creates the following: > > CREATE DATABASE "CISX" WITH OWNER = postgres TEMPLATE = template0 ENCODING = 'SQL_ASCII'; > > > > I don't know whether this is a bug or not as I can't find any hard documentation to say otherwise? > > I'd guess not, because the objects you copied from template1 when making > the database are part of the dumpall output. If you made it from > template1 after the backup you'd get anything that was in the new > template1 plus all of the old objects. > > Ok I understand now... I haven't been using template1 with non-pg_catalog objects. My question now would be, is there an easy way to place your own objects into pg_catalog for template0? (In advance of why... it is much easier to apply any upgrades / patches to my own customisations when they are not backed up into the standard backup - otherwise you have to manually edit the backup file which is much harder to do than apply a patch to the template.) Regards Donald