Jim C. Nasby wrote:
>On Fri, Feb 24, 2006 at 07:58:38AM +0800, Jan Cruz wrote:
>
>
>>On 2/24/06, Michael Glaesemann <grzm@myrealbox.com> wrote:
>>--schema-only flag is the equivalence of -s
>>
>>I also want an option that would exclude "CREATE INDEX " whenever
>>a schema is being dump
>>
>>
>
>At least on my small test database, all the CREATE INDEX commands are
>one-liners. This means it would be trivial to exclude them with
>grep -v 'CREATE INDEX, or grab just them with grep 'CREATE INDEX'. I'd
>just stick the greps in between cat and psql -f -.
>
>
Much better than this, you can do a custom dump and then use
pg_restore's --list and --use-list features to remove the things you
don't want restored. pg_restore is wonderfully flexible.
cheers
andrew