I think so, the parameter you need in psql command is -w mipassword.
But, you have to understand that use this form or set PGPASSWORD aren't safer.
Exist a file (pg_hba.conf) for this process ir task.
Obtener Outlook para Android<https://aka.ms/ghei36>
From: David Gauthier <davegauthie...@gmail.com>
Sent: Friday, April 13, 2018 3:51:33 PM
To: James Keener
Subject: Re: hardcode password in connect string
PGPASSWORD env var works fine.
On Fri, Apr 13, 2018 at 2:46 PM, James Keener
Is setting it as an environment variable an option?
Alternatively, a service file?
On April 13, 2018 2:43:01 PM EDT, David Gauthier
PG v9.5.2 on RHEL
I like to use an alias to connect to my favorite DBs but don't like to enter
passwords. I used to just disable passwords (working behind a firewall), but
this one is different. I see nothing in the interactive connect string where I
can enter the password...
psql -h thehost -U memyselfi mydb
Missing something like "-p mypassword"
Is there a way I can stick the pw in the linux alias definition ?
Just thinking something like this may be available since hardcoded passwords
are supported in perl/dbi, pg driver
Sent from my Android device with K-9 Mail. Please excuse my brevity.