Re: Copy entire schema A to a different schema B - Mailing list pgsql-general

From Ron
Subject Re: Copy entire schema A to a different schema B
Date
Msg-id 9aa9cb06-8bca-910c-5251-d974849dda7c@gmail.com
Whole thread Raw
In response to Copy entire schema A to a different schema B  (Tiffany Thang <tiffanythang@gmail.com>)
Responses Re: Copy entire schema A to a different schema B  (Tiffany Thang <tiffanythang@gmail.com>)
List pgsql-general
On 2/11/19 10:00 AM, Tiffany Thang wrote:
> Hi,
> To copy the source schema A to target schema B in the same database in 
> PG10.3, I use psql to dump schema A and manually removes anything specific 
> to the schema in the text dump file before importing into schema B. How do 
> I achieve the same exporting from Schema A and importing into schema B 
> using pg_dump with the -Fc option? Since the dump file generated is 
> binary, I could not make modifications to the file. Is the procedure the 
> same in version 11?

Why do you need to use "--format=custom" instead of "--format=plain"?

For example:
$ pg_dump --format=plain --schema-only --schema=A


-- 
Angular momentum makes the world go 'round.


pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: Copy entire schema A to a different schema B
Next
From: Tiffany Thang
Date:
Subject: Re: Copy entire schema A to a different schema B