Re: Jboss/Oracle/select 1 form dual

  • From: "Martin Busik" <martin.busik@xxxxxxxx>
  • To: <oracle-l@xxxxxxxxxxxxx>
  • Date: Fri, 8 May 2009 11:00:07 +0200

> Personally, I would shoot anyone who configures a pointless additional
> select statement to check connectivity; I blogged on
> it<http://preferisco.blogspot.com/2006/04/is-this-oracle-wtf.html>a
> couple of years ago and it has come up several times on this list. But
> that's another matter. 

It may become quite hard to find the one, who is doing a "pointless
additional query".

The JDBC interface contains no ping (or isAlive or similiar) method.

Connection pool implementations rely on the JDBC interface, so to check if a
connection
is valid/usable, they can only execute standard conform methods, typically a
"select null from dual".

Without a connection check, application users (and in the next steps admins
and developers) are
bored with more or less regular errors ("The first user on monday morning
gets this exception")

So, a "select null from dual" is the least evil one can choose...

SCNR,
Martin

--
//www.freelists.org/webpage/oracle-l


Other related posts: