From: | Kevin Grittner <kgrittn(at)ymail(dot)com> |
---|---|
To: | Hannes Erven <hannes(at)erven(dot)at>, "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: executeQuery() throws "Statement has been closed" |
Date: | 2014-07-31 14:52:46 |
Message-ID: | 1406818366.83671.YahooMailNeo@web122301.mail.ne1.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
Hannes Erven <hannes(at)erven(dot)at> wrote:
> sometimes my application (jdbc-1101, hibernate, desktop application)
> reports the following "Statement has been closed" error:
> ... I'm wondering why there is even checkClosed() called before
> returning the value of a field?
> Could that check be safely removed?
Not according to the API documentation:
http://docs.oracle.com/javase/7/docs/api/java/sql/Statement.html#getMaxRows%28%29
| Throws:
| SQLException - if a database access error occurs or this method is called on a closed Statement
Besides, if a Statement has been closed, why would you expect it to
still be usable?
--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Hannes Erven | 2014-07-31 19:33:31 | Re: executeQuery() throws "Statement has been closed" |
Previous Message | Dave Cramer | 2014-07-31 14:27:36 | Re: executeQuery() throws "Statement has been closed" |