On windows 7, I want to push my local PostgreSQL database(9.4.0) to remote PostgreSQL server on Heroku(9.3.3), I followed the Heroku PostgreSQL Document to push:
>heroku pg:push postgres HEROKU_POSTGRESQL_NAVY_URL --app salty-atoll-4222
Your version of git is 1.9.5.. Which has serious security vulnerabilities.
More information here: https://blog.heroku.com/archives/2014/12/23/update_your_git_clients_on_windows_and_os_x
'env' is not recognized as an internal or external command,
operable program or batch file.
Password:
! WARNING: Extensions in newly created target database differ from existing source database.
!
! Target extensions:
! extname
! ---------
! plpgsql
! (1 row)
!
!
! Source extensions:
! extname
! -----------
! adminpack
! plpgsql
! (2 rows)
!
!
! HINT: You should review output to ensure that any errors
! ignored are acceptable - entire tables may have been missed, where a dependency
! could not be resolved. You may need to to install a postgresql-contrib package
! and retry.
My local database server URL is localhost:5432. Both the username and database name are postgres, and I've add PGUSER and PGPASSWORD to my system variable, also, my DATABASE_URL system variable is postgres://postgres:password@localhost:5432/postgres.
Also, since it says 'env' is not recognized as an internal or external command, operable program or batch file., I guess set command can be use to replace env, so I also added a alias env.bat in C:\Windows\System32\env.bat:
@ECHO OFF
set
But it still can't recognized env command and my PGPASSWORD variable, asks me to type my password by hand, shows the same warning and my database can't be pushed to this remote server. What's the problem here?
heroku-toolbelt.exeadds to list of system environment variables the variableHerokuPathwith valueC:\Program Files (x86)\Herokuand appends to system environment variablePATHthe folder pathsC:\Program Files (x86)\Heroku\bin;C:\Program Files (x86)\git\cmdon installation of Heroku. This modification on system environment variables is not undone on uninstalling Heroku. Are the environment variablesHerokuPathandPATHdefined on your machine in same way with correct paths?