I have 2 instances of PostgreSQL running on some servers. One on the default port (5432) and the other instance on port 5433. Some users (and processes) only need access to the second instance (5433) and I'd like to set it up so that when those users use commands like psql or createdb in their shell it will automatically direct them to the right Postgres instance instead of them having to type -p 5433 along with every command.
I tried to look this up on www.postgresql.org but was unable to find it...probably my fault. Anyone know how?

createdb? – dezso Sep 12 '12 at 4:05createdbwhen creating a new Rails application so not too often but ever couple weeks. Usingpsqlhappens more often, which prompted this inquiry. Thanks for your help! – Meltemi Sep 12 '12 at 5:22test_patch, which is reallypsql -h [some IP] -p 5432 -d testdb– dezso Sep 12 '12 at 6:29