Search code examples
databasepostgresqlbackuprestorepgadmin

Problem in restoring database from PostgreSQL Version 11


I am trying to restore database from PostgreSQL Version 11 into PostgreSQL Version 10. I am using Windows 7 (32-bit) so I can't use the latest PostgreSQL Version. So I am using PostgreSQL Version 10.

But I am taking backup from database of PostgreSQL Version 11. Because of which I am getting error:

pg_restore: [archiver] unsupported version (1.14) in file header

So, is there any way I can restore my database in PostgreSQL Version 10.

It would be really helpful if any can show me a way out.


Solution

  • Use pg_restore from the newer version to create a plain SQL dump file. Then restore to the older version from that dump file. Depending on what features you are using, the dump file may need to be manually edited before it will restore successfully.