Re: Help to dump tables in a database and restore in another database - Mailing list pgsql-novice

From Thomas Kellerer
Subject Re: Help to dump tables in a database and restore in another database
Date
Msg-id hhv5h6$beb$1@ger.gmane.org
Whole thread Raw
In response to Re: Help to dump tables in a database and restore in another database  (Intengu Technologies <sindile.bidla@gmail.com>)
Responses Re: Help to dump tables in a database and restore in another database  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-novice
Intengu Technologies, 05.01.2010 11:42:
> pg_dump --host localhost --port 5432 --username postgres -o -v -t
> 'myschema.*' dbname>  mydump.sql
>
> This generates an error no matching tables were found, is the asterisk
> not a wild card meaning all tables found in the schema named myschema

No. The wildcard character in SQL is %

But to select all tables from a specific schema, you can use the -n switch:

pg_dump -n myschema  ...

Check out pg_dump's documentation (Joshua has already posted the link)

Thomas


pgsql-novice by date:

Previous
From: Tom Lane
Date:
Subject: Re: "could not read block" error message
Next
From: Matthew Kirk
Date:
Subject: upgrade from 32 bit to 64 bit within same postgresql major release (e.g. 8.3.x)