Hello, I think I have found a feature of pg_restore that may be a bug.
If the --clean option AND --dbname=database option are used with an initially empty database, the restoration fails, although the very same options with a "| psql database" works fine. The internal psql with --dbname option fails at the generated clean stuff if the database is empty, as the ALTER and DROP tables are reported to fail and the generation is stopped. In the piped version, these initial errors are ignored. sh> createdb comics sh> pg_restore --clean --no-owner --no-acl --dbname=comics comics.dbz pg_restore: [archiver (db)] could not execute query: ERROR: relation "public.a_ecrit" does not exist However it works fine without the "--clean" option. It seems that the instruction that fails is : ALTER TABLE ONLY public.a_ecrit DROP CONSTRAINT "$2"; It would make sense to ignore some alter/drop errors in pg_restore. -- Fabien Coelho - [EMAIL PROTECTED] ---------------------------(end of broadcast)--------------------------- TIP 4: Don't 'kill -9' the postmaster