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x5IG5v dGlmeSB0aGUgc2VuZGVyIGJ5IHJldHVybiBlLW1haWwsIGFuZCBkZWxldGUg dGhlIG9yaWdpbmFsIG1lc3NhZ2UgYW5kIGFsbCBjb3BpZXMgZnJvbSB5b3Vy IHN5c3RlbS4gVGhhbmsgeW91LiAKLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0t LS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0t LS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0tLS0KCg==
Wang Haiyong <wanghaiyong@neusoft.com> writes: > pg_restore 8.1.0 parameter( -n) not work¡£ This is fixed in 8.1.4. 2006-04-12 18:19 tgl * src/bin/pg_dump/: pg_backup_archiver.c, pg_restore.c (REL8_1_STABLE): Fix pg_restore -n option to do what the man page says it does. The original coding only worked if one of the selTypes restriction options was also given. Per report from Nick Johnson. regards, tom lane