How to automate password requests?

From: Marten Lehmann <lehmann(at)cnm(dot)de>
To: pgsql-general(at)postgresql(dot)org
Subject: How to automate password requests?
Date: 2007-11-28 18:37:18
Message-ID: 474DB55E.8080507@cnm.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello,

I'm trying to automate some postgresql scripts, but I cannot find a way
to pass a password directly to commands like pg_dump psql and so on.
Even a

echo "password" | psql

doesn't work, the password prompt of psql is still waiting.

mysql has the -p option. What would be the postgresql equivalent? I
don't want to enter passwords dozend times.

Regards
Marten

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Hart 2007-11-28 18:39:56 Re: How to automate password requests?
Previous Message Trevor Talbot 2007-11-28 18:33:08 Re: Linux v.s. Mac OS-X Performance