Thread: psql prompting for password. Can we suppress it?
Hello, =20 We are trying to perform bulk insert into PostGre database with the help of a text file (containing n INSERT statements), and then invoking psql command from a batch file. =20 "psql -d <database name> -f <file-name.sql> -h <server-ip> -U <username>" =20 The issue is that the psql command window prompts for the password. Have you got any idea how to suppress it?=20 =20 Thanks in advance. =20 Best Regards, Pradeep Rai (New Delhi, India)
Pradeep Rai напиÑа: > Hello, > > We are trying to perform bulk insert into PostGre database with the help of > a text file (containing n INSERT statements), and then invoking psql command > from a batch file. > > "psql -d <database name> -f <file-name.sql> -h <server-ip> -U <username>" > > The issue is that the psql command window prompts for the password. Have you > got any idea how to suppress it? 1.http://www.postgresql.org/docs/current/static/libpq-pgpass.html 2.http://www.postgresql.org/docs/current/static/auth-methods.html#AUTH-TRUST -- Milen A. Radev