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

Re: How to retry when connection has been closed?

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: Herouth Maoz <herouth(at)unicell(dot)co(dot)il>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: How to retry when connection has been closed?
Date: 2009-08-02 22:20:47
Message-ID: 4A76113F.8020101@opencloud.com (view raw or flat)
Thread:
Lists: pgsql-jdbc
Herouth Maoz wrote:

> Is there a more elegant way to find out whether the connection has been 
> dropped from within the catch clause?

Test the SQLState of the thrown SQLException. See
http://www.postgresql.org/docs/8.4/static/errcodes-appendix.html

-O

In response to

pgsql-jdbc by date

Next:From: Kris JurkaDate: 2009-08-03 17:44:26
Subject: Re: Datatype of domains not reported correctly.
Previous:From: Herouth MaozDate: 2009-08-02 09:12:55
Subject: How to retry when connection has been closed?

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