--- Jan Wieck <JanWieck@yahoo.com> wrote:
> #!/bin/sh
>
> (
> echo "start transaction;"
> cat $2
> echo "commit transaction;"
> ) psql $1
>
>
>
> then call it as
>
> reload_in_transaction my_db my_namespace.dump
>
> Since the whole dump will be restored inside of one transaction, nobody
> will see it while it's reloading.
Interesting idea. I know some RDBMSs that are very picky about DDL in
transactions but it appears pgSql handles it without any problems.
My concern though ... wouldn't pgSql server collapse when faced with
transaction spawning across 100M+ records? And how would that affect overall
restore time? I've should've tried it myself but I can't, my "regular"
pg_restore has been running for 4+ hours, can't kill now ...
Thanks
__________________________________
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree