Re: pg_dump --clean w/ <= 7.2 server - Mailing list pgsql-patches

From Tom Lane
Subject Re: pg_dump --clean w/ <= 7.2 server
Date
Msg-id 13898.1088087541@sss.pgh.pa.us
Whole thread Raw
In response to Re: pg_dump --clean w/ <= 7.2 server  (Christopher Kings-Lynne <chriskl@familyhealth.com.au>)
Responses Re: pg_dump --clean w/ <= 7.2 server  (Kris Jurka <books@ejurka.com>)
List pgsql-patches
Christopher Kings-Lynne <chriskl@familyhealth.com.au> writes:
>> When running pg_dump --clean against a server that doesn't have schemas
>> the namespace is blank and ends up producing a dump full off things like:
>>
>> DROP TABLE "".tab;

> Since the person is dumping using 7.5 pg_dump, presumably they will be
> restoring to 7.5, and it should be:

> DROP TABLE "public".tab;

Possibly the most correct solution is to assign the name "public" to the
dummy schema that pg_dump creates internally when talking to a pre-7.3
server.

I seem to recall that there was some reason for using "", but I don't
recall what exactly.

            regards, tom lane

pgsql-patches by date:

Previous
From: Christopher Kings-Lynne
Date:
Subject: Re: pg_dump --clean w/ <= 7.2 server
Next
From: "Serguei Mokhov"
Date:
Subject: Translation updates for 7.4/7.5: postgres-ru.po