Reputation: 20078
What does it mean I'm trying to restore my postgresql db and here is what I'm getting but I do not see it restore tables/data/
C:\Program Files\PostgreSQL\9.4\bin\pg_restore.exe --host 123-97.compute-1.amazonaws.com --port 5432 --username "username" --dbname "mydb" --no-password --section pre-data --section data --section post-data --schema public --verbose "C:\db\employee.backup"
pg_restore: connecting to database for restore pg_restore: implied data-only restore
Process returned exit code 0.
I'm using Windows 8.1
Upvotes: 8
Views: 18482
Reputation: 85
For backup purposes, rename your old schema eg. schema_old and create a new schema with the same name, and try to restore it again.
Upvotes: 0
Reputation: 11
i faced same issue when tried to restore psql 12 backup into psql 12 database but with newer ubuntu version (backup was on ubuntu 18 and restore on ubuntu 20 ,both are psql 12). when i downgraded ubuntu from 20 to 18 it restored just normally, not sure why ubuntu version should make problem. my advice just make sure environment of backup and restore are exactly the same.
Upvotes: 0
Reputation: 91
I was getting this error while restoring schema backup with different name. When i restored the schema with same name it worked like a charm and then later I renamed it.
Alternative: do pg_restore
from a carefully-restricted pg_dump
dump and avoid --schema
(and possibly even --table
) options when using pg_restore
.
Upvotes: 9