pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Viorel Dragomir <bc@vio.ro>
To: pgsql-sql@postgresql.org
Subject: Re: pg_dump "feature"
Date: Wed, 16 Jul 2003 17:43:54 +0300
Message-ID: <00be01c34ba8$aec682e0$0600a8c0@fix.ro> (raw)
References: <004501c34b9f$f7d8f520$0600a8c0@fix.ro>
	<18025.1058365770@sss.pgh.pa.us>

Thanks for the answer[s].
Interesting that when i launch the command from php through exec() it works
fine even on pg_dump 7.3.x
I guess this feature works only on [shell] command line.

This is the php code:

        $tmp_fname = tempnam("/tmp", "file-");
        $f = fopen($tmp_fname, "w");
        fwrite($f, "$username\n".USER_DB_PASSWORD."\n");
        fclose($f);

        $cmd = "pg_dump $add_cmd $export $add_table < $tmp_fname";
        $result = system($cmd);
        unlink($tmp_fname);

----- Original Message -----
From: "Tom Lane" <tgl@sss.pgh.pa.us>
To: "Viorel Dragomir" <bc@vio.ro>
Cc: <pgsql-sql@postgresql.org>
Sent: Wednesday, July 16, 2003 5:29 PM
Subject: Re: [SQL] pg_dump "feature"


> "Viorel Dragomir" <bc@vio.ro> writes:
> > In 7.3.x the pg_dump accepts the password only from stdin. The user must
en=
> > ter his password.
> > It's a feature or a bug, because i can't see any logic in this
behaviour.
>
> It's a feature ... or at least an intentional change.
>
> If you want to keep your password in a file, see the ~/.pgpass feature.
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 9: the planner will ignore your desire to choose an index scan if your
>       joining column's datatypes do not match




view thread (4+ messages)

Message-ID: <00be01c34ba8$aec682e0$0600a8c0@fix.ro>
Permalink:  ../00be01c34ba8$aec682e0$0600a8c0@fix.ro/
Also on:    postgresql.org/message-id/00be01c34ba8$aec682e0$0600a8c0@fix.ro

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: bc@vio.ro
  Subject: Re: pg_dump "feature"
  In-Reply-To: <00be01c34ba8$aec682e0$0600a8c0@fix.ro>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox