Skip site navigation (1) Skip section navigation (2)

Re: BUG #5246: Misleading/inconsistent SQLSTATE behavior

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Chris Travers" <chris(dot)travers(at)gmail(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #5246: Misleading/inconsistent SQLSTATE behavior
Date: 2009-12-16 21:12:39
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-bugs
"Chris Travers" <chris(dot)travers(at)gmail(dot)com> writes:
> 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.

> For example, if a connection fails due to a database not found, the backend
> registers 3D000 as a SQL state, but the front-end registers 25P01.  If a
> login fails, the back-end registers 28000 but the front-end registers 25P01
> again.

Exactly what "frontend" are you talking about here?  Because what this
sounds like to me is a client-side programming error.  It's certainly
not the backend's fault, and I doubt it is libpq's either.

			regards, tom lane

In response to


pgsql-bugs by date

Next:From: Chris TraversDate: 2009-12-16 21:16:12
Subject: Re: BUG #5246: Misleading/inconsistent SQLSTATE behavior
Previous:From: Magnus HaganderDate: 2009-12-16 21:03:48
Subject: Re: pgstat wait timeout (by Robert Schnabel)

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group