Re: Getting "This ResultSet is closed" exceptions

From: "Andres Olarte" <olarte(dot)andres(at)gmail(dot)com>
To: "Paul Tomblin" <ptomblin(at)gmail(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Getting "This ResultSet is closed" exceptions
Date: 2008-02-18 19:10:56
Message-ID: 3fccaa690802181110j4b5d1429ta8ea641f4ebb160@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

You might go for using a single connection per thread. Works for me.

On Feb 18, 2008 12:59 PM, Paul Tomblin <ptomblin(at)gmail(dot)com> wrote:
> On Feb 18, 2008 1:51 PM, Andres Olarte <olarte(dot)andres(at)gmail(dot)com> wrote:
> > Another thread my close the result set if it's using the same
> > statement. Or the thread may close the connection, but i think that
> > would throw another exception. Other wise your code look right
>
> Well, no other method is using the same PreparedStatement. So I guess
> it's likely that another thread is doing the same query, and that's
> what's closing the ResultSet. I guess it's time to make some of these
> methods synchronized.
>
> --
> For my assured failures and derelictions I ask pardon beforehand of my
> betters and my equals in my Calling here assembled, praying that in
> the hour of my temptations, weakness and weariness, the memory of this
> my Obligation and of the company before whom it was entered into, may
> return to me to aid, comfort and restrain.
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: explain analyze is your friend
>

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message peter royal 2008-02-18 19:14:03 Re: Implementing setQueryTimeout()
Previous Message Paul Tomblin 2008-02-18 18:59:31 Re: Getting "This ResultSet is closed" exceptions