This question already has an answer here:
这个问题已经有了答案:
- how to restore postgresql DB without backup 3 answers
- 如何在没有备份3个答案的情况下恢复postgresql DB
I've installed postgrSQL 9.0 successfully and I have separate database file (database.backup
). Now I need to add this database into postgreSQL. I am new to this postgreSLQ. I would be much appreciated if anyone please be so kind enough to explain how to do such a thing.
我已经成功地安装了postgrSQL 9.0,并且有单独的数据库文件(database.backup)。现在我需要将这个数据库添加到postgreSQL中。我是新来的。如果有人能解释一下如何做这样一件事,我将不胜感激。
Thanks a lot
非常感谢
1 个解决方案
#1
3
Use PgAdmin-III to restore the DB, or use the pg_restore
command, which does the same thing at the command line.
使用PgAdmin-III恢复数据库,或者使用pg_restore命令,该命令在命令行中执行相同的操作。
See the PgAdmin-III docs.
看到PgAdmin-III文档。
I don't use PgAdmin-III, I work from the command line but from memory you need to:
我不使用PgAdmin-III,我从命令行工作,但是从内存中你需要:
- Connect PgAdmin-III to the DB
- 将PgAdmin-III连接到DB
- Create a blank database
- 创建一个空数据库
- Right click on it
- 右键点击它
- Choose "Restore...."
- 选择“恢复....”
- Pick the ".backup" file
- 选择”。备份”文件
#1
3
Use PgAdmin-III to restore the DB, or use the pg_restore
command, which does the same thing at the command line.
使用PgAdmin-III恢复数据库,或者使用pg_restore命令,该命令在命令行中执行相同的操作。
See the PgAdmin-III docs.
看到PgAdmin-III文档。
I don't use PgAdmin-III, I work from the command line but from memory you need to:
我不使用PgAdmin-III,我从命令行工作,但是从内存中你需要:
- Connect PgAdmin-III to the DB
- 将PgAdmin-III连接到DB
- Create a blank database
- 创建一个空数据库
- Right click on it
- 右键点击它
- Choose "Restore...."
- 选择“恢复....”
- Pick the ".backup" file
- 选择”。备份”文件