Re: pg_dump not dumping some schemas

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



It doesn’t show up in custom format dump either… I begin to wonder if it’s
a bug in pg_dump.


-bash-4.1$ pg_dump -s -n test -Fc polling_etl | pg_restore -l | grep SCHEMA
-bash-4.1$ pg_dump -s -n test2 -Fc polling_etl | pg_restore -l | grep
SCHEMA
7; 2615 1131042 SCHEMA - test2 pb_writer



On 6/1/15, 4:07 AM, "Albe Laurenz" <laurenz.albe@xxxxxxxxxx> wrote:

>Yun Guo wrote:
>>>> I use this command to dump schema:
>>>> pg_dump -s -n test polling_etl  > file.sql
>>>>
>>>> However, the file.sql file includes creation of all the objects in
>>>> schema test, but not the creation of test schema itself.
>
>>>> polling_etl=# \dn+ test
>>>>                 List of schemas
>>>>  Name | Owner | Access privileges | Description
>>>> ------+-------+-------------------+-------------
>>>>  test | test  | test=UC/test     +|
>>>>       |       | pb_writer=UC/test+|
>>>>       |       | =U/test          +|
>>>>       |       | postgres=U*C/test |
>
>> I tried again. It¹s still not dumping CREATE SCHEMA. And weirdly it
>>would
>> work for some other schemas in the same database.
>> 
>> -bash-4.1$ pg_dump -s -n test polling_etl | grep 'CREATE SCHEMA'
>> -bash-4.1$ pg_dump -s -n test2 polling_etl | grep 'CREATE SCHEMA'
>> CREATE SCHEMA test2;
>
>That is disturbing.
>
>Does the schema show up in a custom format dump?
>
>pg_dump -s -n test -Fc polling_etl | pg_restore -l
>
>Yours,
>Laurenz Albe


-- 
Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin





[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux