Re: Revisiting BUG #3684: After dump/restore, schema PUBLIC always exists - Mailing list pgsql-bugs

From Pedro Gimeno
Subject Re: Revisiting BUG #3684: After dump/restore, schema PUBLIC always exists
Date
Msg-id 1194651754l.7868l.4l@dirtecnica.formauri.es
Whole thread Raw
In response to Re: Revisiting BUG #3684: After dump/restore, schema PUBLIC always exists  (Bruce Momjian <bruce@momjian.us>)
Responses Re: Revisiting BUG #3684: After dump/restore, schema PUBLIC always exists
List pgsql-bugs
Bruce Momjian wrote:

> The fact is that 'public' is created from template1, so I suppose if
> you remove it from there then new databases will not have it.

That could cause installers for packages using PostgreSQL to fail if=20=20
they create databases and expect "public" to exist.

Furthermore I make my dumps with option -C for pg_dump. The CREATE=20=20
DATABASE statement it generates uses template0 as the template.

> I think it would be odd for pg_dump to remove something that was in
> the database before the restore started.  I am afraid removing it=20=20
> yourself is the only logical option for us.

If that's really the case then please add a note in the docs stating=20=20
that deleted objects may revive, so it's no surprise for those who face=20=
=20
that for the first time.

-- Pedro Gimeno

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #3730: Creating a swedish dictionary fails
Next
From: Pedro Gimeno
Date:
Subject: Re: Revisiting BUG #3684: After dump/restore, schema PUBLIC always exists