Re: libpq and TOO MANY CONNECTIONS

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Dmitriy Igrishin <dmitigr(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: libpq and TOO MANY CONNECTIONS
Date: 2010-08-12 18:13:54
Message-ID: 2449.1281636834@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Dmitriy Igrishin <dmitigr(at)gmail(dot)com> writes:
> It seams, that all of the error codes should be obtained by calling
> PQresultErrorField().
> But this function works only with results. So in what situations
> TOO MANY CONNECTIONS error may be thrown after successfully connection ? :)

It isn't.

The lack of a way to report a SQLSTATE code for a connection failure is
an API shortcoming in libpq; it's not the backend's problem.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2010-08-12 18:20:49 Re: CommitFest 2010-07 week four progress report
Previous Message Robert Haas 2010-08-12 18:12:25 Re: including backend ID in relpath of temp rels - updated patch