Re: pg_receivexlog always handles -d option argument as connstr - Mailing list pgsql-hackers

From Amit Kapila
Subject Re: pg_receivexlog always handles -d option argument as connstr
Date
Msg-id CAA4eK1KOhBex7vtKPhQnBq4zTiF7Yi4YJEH=q6ez2yU2ZhMCrw@mail.gmail.com
Whole thread Raw
In response to pg_receivexlog always handles -d option argument as connstr  (Sawada Masahiko <sawada.mshk@gmail.com>)
Responses Re: pg_receivexlog always handles -d option argument as connstr
List pgsql-hackers
On Mon, Oct 6, 2014 at 10:23 PM, Sawada Masahiko <sawada.mshk@gmail.com> wrote:
>
> Hi all,
>
> pg_receivexlog always handles argument of -d option as  connstr formatted value.
> We can doubly specify host name, port number.
> The other client tools handles -d option as connstr value only if
> argument has "=" character.

pg_basebackup also seems to behave same as pg_receivexlog.
psql also treats it in similar way.  The behaviour of psql is as
below:
psql.exe -d="host=localhost port=5432 dbname=postgres"
psql: invalid connection option ""

psql.exe -d "host=localhost port=5432 dbname=postgres"
psql (9.5devel)
WARNING: Console code page (437) differs from Windows code page (1252)
         8-bit characters might not work correctly. See psql reference
         page "Notes for Windows users" for details.
Type "help" for help.

postgres=#

> The document says that pg_receivexlog ignores database name, and this
> option is called for consistency with other client applications.
> But if we specify database name like other client tool '-d hoge' ,
> then we will definitely got error.

What I understand from document is that it ignores database name
when given in connection string.


With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com

pgsql-hackers by date:

Previous
From: Peter Geoghegan
Date:
Subject: Re: Promise index tuples for UPSERT
Next
From: Robert Haas
Date:
Subject: Re: TAP test breakage on MacOS X