Hi everyone,

to import a new version of the schema, I create and restore a dump as follows:


pg_dump --data-only --oids --file $dumpfile $db_name
psql -1 […] $db_name < $schemafile
psql -1 […] $db_name < $dumpfile


However, when the dump is restored, I get the following error message:

ERROR: duplicate key value violates unique constraint "pg_largeobject_loid_pn_index"

I tried to clear the pg_largeobject table before restoring the dump, but this leads to errors like "PSQLException: ERROR: large object 23313 does not exist" when I access the data afterwards.

Thanks a lot for any hints!

-- Andreas

--
Andreas Hartmann, CTO
BeCompany GmbH
http://www.becompany.ch
Tel.: +41 (0) 43 818 57 01

Reply via email to