Re: [PATCHES] default database creation with initdb - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PATCHES] default database creation with initdb
Date
Msg-id 6974.1119278887@sss.pgh.pa.us
Whole thread Raw
In response to Re: [PATCHES] default database creation with initdb  (Andreas Pflug <pgadmin@pse-consulting.de>)
Responses Re: [PATCHES] default database creation with initdb
List pgsql-hackers
Andreas Pflug <pgadmin@pse-consulting.de> writes:
> Tom Lane wrote:
>> If it's a server-side failure it should have a SQLSTATE code.

> Specifically, I'm talking about

> "no pg_hba.conf entry for ....",

ERRCODE_INVALID_AUTHORIZATION_SPECIFICATION

> "Ident authentication failed.." (both server sice)

Ditto.  Do you need to know the difference?  What exactly would client
code do differently for these two cases?

> and  "Is the server running on host ..." from libpq 

libpq doesn't currently assign SQLSTATEs to internally detected errors
... someday someone should fix that.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: quote_boolean() and friends missing
Next
From: "Dave Page"
Date:
Subject: Re: [PATCHES] default database creation with initdb