From: | Mark Zhitomirski <zhmark(at)yahoo(dot)com> |
---|---|
To: | pgadmin-support(at)postgresql(dot)org |
Subject: | SOLVED: pgAdmin does respect pgpass.conf when opening .sql files |
Date: | 2009-10-22 10:51:44 |
Message-ID: | 635170.30310.qm@web52302.mail.re2.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgadmin-support |
Thanks, Dave,
the problem was caused by me choosing arbitrary name for "server" in Servers tree in Object browser - browser had no problem opening it so I concluded erroneously that host/IP is what matters in pgpass.conf. Once I've renamed "server" to 'localhost' problem has gone.
--MZ
________________________________
From: Dave Page <dpage(at)pgadmin(dot)org>
To: Mark Zhitomirski <zhmark(at)yahoo(dot)com>
Cc: pgadmin-support(at)postgresql(dot)org
Sent: Thu, October 22, 2009 12:28:11 PM
Subject: Re: [pgadmin-support] pgAdmin does not respect pgpass.conf when opening .sql files?
On Wed, Oct 21, 2009 at 5:42 PM, Mark Zhitomirski <zhmark(at)yahoo(dot)com> wrote:
> Hi!
> pgAdmin 1.10.0 on Windows XP
> PostgreSQL 8.3.3 on the same machine (localhost:5432)
>
> When I'm opening some .sql file (in Windows Explorer) pgAdmin starts and
> presents dialog "Connect to Server"
> with lines Server, Database and Username
> I fill those lines and press "OK"
> dialog asks for password. (Question 1 - Why? it has it saved already, most
> probably in pgpass.conf) Then "Query" window appears. I'm done working with
> that .sql file and close pgAdmin.
Are you sure the saved password has the same hostname/ip etc? (eg.
127.0.0.1 vs. 192.168.1.57 or whatever your primary interface uses).
FYI, the saved password is used when I test here - I don't get a
password prompt.
> When I'm opening another .sql file lines Server, Database and Username has
> my previous input. Password prompt happens again. Question 2 - is it
> possible to avoid this prompt?
Well, you could associate the file type with a script which launches
pgAdmin with '-qc <connect string> -f $1' (modified appropriately for
whatever operating system you use).
--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com
PGDay.EU 2009 Conference: http://2009.pgday.eu/start
From | Date | Subject | |
---|---|---|---|
Next Message | Elie Hani | 2009-10-23 08:28:59 | Adding routes |
Previous Message | Dave Page | 2009-10-22 08:28:11 | Re: pgAdmin does not respect pgpass.conf when opening .sql files? |