When you say “going,” it looks like you are using the command cdto modify this directory. Sort of:
$ cd /opt/local/lib/postgresql84/bin
$ psql
psql: command not found
Typically on Unix systems, the current directory is not included in your executable search path. Therefore, either explicitly execute psqlfrom the current directory with ./:
$ cd /opt/local/lib/postgresql84/bin
$ ./psql
or, add the directory to your PATH:
$ export PATH=/opt/local/lib/postgresql84/bin:$PATH
$ psql
source
share