JDBC Driver Class: Connection Method: isClosed() error

Поиск
Список
Период
Сортировка
От Oscar FRANCOIS
Тема JDBC Driver Class: Connection Method: isClosed() error
Дата
Msg-id sae83897.000@wise.e-contact.fr
обсуждение исходный текст
Ответы Re: JDBC Driver Class: Connection Method: isClosed() error  (Peter T Mount <peter@retep.org.uk>)
Список pgsql-bugs
Hi,

  Here are the maximum information about the error:

OS where the class is running: winnt4 with jdk1.3
DB OS: Linux Debian potatoe
Postgresql version: 7.0.3
Driver JDBC: included in the source code.

Description:
-----------
First case (postmaster is running ok):
I get the connection with:
conn = DriverManager.getConnection("...
I do a sleep for 5 seconds
I test the code with the isClosed() function.
I do a request like "select * from ...."
Finally I close the connection.

But If I do the following:
I get the connection with:
  conn = DriverManager.getConnection("...
I do a sleep for 5 seconds
(during while I stop the postmaster)
I test the code with the isClosed() function.
---> WHICH RETURN FALSE!!! <-----
I do a request like "select * from ...."
---> which generate a SQLException Error <---
Finally I close the connection.
---> which generate a SQLException Error <---

  Why the Hell, does the method isclosed() is answering that everything is Ok whereas the postmaster
is closed & the next request generate an Error.

Thanks in advance for further details.

Regards,

Oscar FRANCOIS.

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Optimalisation options change query results
Следующее
От: Boulat Khakimov
Дата:
Сообщение: alter table rename bug