Re: [GENERAL] pg_dump question (exclude schemas)

2013-09-06 Thread vinayak

>I want to backup a database but exclude certain schemas with a patter.
>I have 100 schemas with the pattern:  'sch_000', 'sch_001',  and so on.
>Will this work?
>$pg_dump   --exclude-schema='sch_*'
>this does not seem to exclude all schemas with this pattern  ( 'sch_*' ),
>anything wrong here?
>thanks

It works fine on PostgreSQL 9.2.1.
When both -n and -N are given, the behavior is to dump just the schemas that
match at least one -n switch but no -N switches. If -N appears without -n,
then schemas matching -N are excluded from what is otherwise a normal dump.



--
View this message in context: 
http://postgresql.1045698.n5.nabble.com/pg-dump-question-exclude-schemas-tp5768872p5769872.html
Sent from the PostgreSQL - general mailing list archive at Nabble.com.


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


Re: [GENERAL] pg_dump question (exclude schemas)

2013-08-28 Thread Luca Ferrari
On Wed, Aug 28, 2013 at 9:30 PM, Jay Vee  wrote:

> $pg_dump   --exclude-schema='sch_*'
>
> this does not seem to exclude all schemas with this pattern  ( 'sch_*' ),
> anything wrong here?

The option is fine and works for me on 9.2.4, I suspect the  could do a clash with the -N (exclude-schema).

Luca


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


Re: [GENERAL] pg_dump question (exclude schemas)

2013-08-28 Thread Adrian Klaver

On 08/28/2013 12:30 PM, Jay Vee wrote:

I want to backup a database but exclude certain schemas with a patter.

I have 100 schemas with the pattern:  'sch_000', 'sch_001',  and so on.

Will this work?

$pg_dump   --exclude-schema='sch_*'

this does not seem to exclude all schemas with this pattern  ( 'sch_*'
), anything wrong here?


What version of Postgres?

What is the complete command line?

Does it exclude any of the schemas?




thanks


J.V.



--
Adrian Klaver
adrian.kla...@gmail.com


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


[GENERAL] pg_dump question (exclude schemas)

2013-08-28 Thread Jay Vee
I want to backup a database but exclude certain schemas with a patter.

I have 100 schemas with the pattern:  'sch_000', 'sch_001',  and so on.

Will this work?

$pg_dump   --exclude-schema='sch_*'

this does not seem to exclude all schemas with this pattern  ( 'sch_*' ),
anything wrong here?

thanks


J.V.