Re: BUG #5246: Misleading/inconsistent SQLSTATE behavior

From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "Chris Travers" <chris(dot)travers(at)gmail(dot)com>, <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #5246: Misleading/inconsistent SQLSTATE behavior
Date: 2009-12-16 20:35:07
Message-ID: 4B28F01B020000250002D62C@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Chris Travers" <chris(dot)travers(at)gmail(dot)com> wrote:

> I am noticing that that a failed database connection results in an
> unusable SQLSTATE in libpq, and a very different SQLSTATE than the
> backend registers.

Well, if the client fails to connect to the server, I'm not sure how
the server could communicate its SQLSTATE to the client, in order to
force them to match.

> For example, if a connection fails due to a database not found,
> ... the front-end registers 25P01.

I would have expected something in the 08 class, like maybe 08001 or
08004.

> login fails, ... the front-end registers 25P01 again.

That definitely sounds like it should use 08001.

-Kevin

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Chris Travers 2009-12-16 20:48:20 Re: BUG #5246: Misleading/inconsistent SQLSTATE behavior
Previous Message David Lerner 2009-12-16 18:14:22 BUG #5247: postgres.exe not updating