【问题标题】:How to use pg_restore on Windows Command Line?如何在 Windows 命令行上使用 pg_restore?
【发布时间】:2016-09-03 09:43:12
【问题描述】:

我已经从我的 Heroku 应用下载了一个 PG 数据库备份,它在我的存储库文件夹中作为 latest.dump

我已经在本地安装了postgres,但是我不能在windows命令行上使用pg_restore,我需要运行这个命令: pg_restore --verbose --clean --no-acl --no-owner -j 2 -h localhost -d DBNAME latest.dump

但是找不到命令!

【问题讨论】:

    标签: python django database postgresql heroku


    【解决方案1】:

    由于您在 Windows 上,因此您的路径上可能没有 pg_restore。 您可以在 postgresql 安装的 bin 中找到 pg_restore,例如c:\program files\PostgreSQL\9.5\bin.

    您可以导航到正确的位置,或者只是将位置添加到您的路径中,这样您就不需要总是导航。

    【讨论】:

      猜你喜欢
      • 2016-12-13
      • 2020-08-10
      • 2012-03-21
      • 2018-11-17
      • 1970-01-01
      • 2011-11-10
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多