heroku pull postgresql on windows

前端 未结 2 1881
孤独总比滥情好
孤独总比滥情好 2021-01-19 17:43

I\'m trying to pull a heroku database to my local Windows computer by using

heroku pg:pull HEROKU_POSTGRESQL_DATABASE mydatabase --app myapp
<
相关标签:
2条回答
  • 2021-01-19 18:31

    I realize this is from months ago, but I'll answer in hopes of helping somebody else. You need to set your path variables. My Computer > Advanced system settings; Click on "Environment variables" and then look at "System variables". Scroll down to "Path" or "PATH", edit it, and go to the very end of the text box. Add ;C:\Program Files (x86)\PostgreSQL\9.3\bin and ;C:\Program Files (x86)\PostgreSQL\9.3\lib (or whatever your equivalent paths are for bin and lib). Restart your command prompt and it should work. :)

    0 讨论(0)
  • 2021-01-19 18:37

    I believe the answer given here is really inaccurate so I will answer:

    See, when there is an error such as "'env' is not recognized as an internal or external command, operable program or batch file" it means that the system is trying to execute a command named env. This has nothing to do at all with setting up your environment variables.

    Env is not a command in windows, but in unix. I understand that you have a windows machine though. What you can do is run "git bash". (You could get it by itself but it comes with Heroku's CLI).

    This gives you a unix-like environment where the "env" command is supported, and then you can run the actual heroku pg:pull command :)

    I hope this helps!

    0 讨论(0)
提交回复
热议问题