[Django]–bash: createdb: command not found

3👍

You set the PATH variable in your user account, and then you su’d to a different user. That user does not inherit your environment, including your path.

You need to set the environment for that user, or else use the full path to the createdb command.

export PATH=/Library/PostgreSQL/9.5/bin/:$PATH
createdb erikb

Leave a comment