Bug 105684 - DB Explorer should detect the version of the driver and report it it's not a supported version
DB Explorer should detect the version of the driver and report it it's not a ...
Status: NEW
Product: db
Classification: Unclassified
Component: DB schema
6.x
All All
: P2 (vote)
: TBD
Assigned To: Libor Fischmeistr
issues@db
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-06-05 05:03 UTC by David Vancouvering
Modified: 2013-09-04 08:22 UTC (History)
2 users (show)

See Also:
Issue Type: ENHANCEMENT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Vancouvering 2007-06-05 05:03:19 UTC
There are many many questions on the nbusers list about "why can't I see my
tables and stored procedures, even though they exist?"  This is almost *always*
because the user is using an older version of the driver.

I believe we could really improve the usability of the DB Explorer if we
maintained a list of drivers that we knew worked, and when someone registers a
driver that is not in that list, we warn them that they may not be able to see
their database metadata with this driver, and point them to the latest driver
that we support.

Barring this, we should *at least* report a visible error (e.g. with a dialog
box) when we are unable to get the metadata for a given database.
Comment 1 David Vancouvering 2007-06-05 18:16:45 UTC
This is related to issue 84654, that a lot of people are hitting.
Comment 2 David Vancouvering 2007-06-27 21:17:48 UTC
From the Wiki, Lance says:
am not sure what you mean by out of date. Are you suggesting that a JDBC driver is not at a minimum JDBC version? What
should happen is NB should check the JDBC major version via DatabaseMetaData.getJDBCMajorVersion() and then call the
method that should be available. Trying to track driver specific versions is a no win scenario - Lance

I say:
I don't know what the errors are that cause older drivers to fail. If it's because we're calling the wrong method, we
could try and call the right method, but I think it's bugs in the drivers that got fixed in later versions. I also don't
want to spend time trying to support older drivers. why is tracking driver versions a no-win situation? P.S. I'm moving
these comments to the issue, and we can continue our conversation there...
Comment 3 David Vancouvering 2007-06-28 19:27:09 UTC
I just remembered there are two places where metadata can be a problem, and where people get confused: in DB Explorer,
and at design time in the visualweb module.  

These two places use two different mechanisms to obtain metadata.  DB Explorer uses DatabaseMetaData.  In visualweb, the
metadata is for a particular command (e.g. "SELECT foo, bar FROM baz") and thus can't be obtained through
DatabaseMetaData.  Metadata is obtained instead from the RowSetMetaData from the rowset underlying the query.

Also, visualweb right now may have a different list of drivers that it supports versus Database Explorer.

We should probably create a separate issue for visualweb, and leave this one focused on the DB Explorer...
Comment 4 _ jimdavidson 2007-06-28 21:56:05 UTC
Unfortunately, things aren't simple here.

As Lance says, I don't think we should get into the business of tracking specific driver versions.  

We can check the JDBC major versions, and report a mismatch there.  That would catch the case where the have a really
old version, but otherwise that's rarely good enough.  Drivers will claim compliance with a particular version, but fail
on specific calls.  They may even return a result which is incorrect, which is a Bad Thing.  Even drivers that we
support may be missing functionality.

What we should do, IMO, is to respond appropriately when we hit a missing or incorrect method.  We typically discover
those empirically, as users report problems and we put checks into the code.  I think this is more effective that
checking driver versions, because we need to do it anyway.

We should also make sure that we have an up-to-date list of supported drivers in our release notes, but that goes
without saying.

Other than the check for the right JDBCMajorVersion (which can probably be done when the connection is created), I don't
think there's much to do here, except to ensure that we catch and respond appropriately to driver failures.
Comment 5 David Vancouvering 2007-07-13 17:37:44 UTC
I'm no longer working on this right now, so I'm trying to move it from the STARTED state.  We'll see if reassigning to
me does the trick.
Comment 6 Jiri Rechtacek 2009-10-16 14:04:07 UTC
Reassigned to new owner.
Comment 7 matthias42 2012-04-17 18:47:30 UTC
I would close this bug as wontfix - I doubt there will be enough manpower to maintain a white list and a blacklist won't do much good.

One idea: To leverage the differences in the DBMS not caught on the JDBC level one could use the hibernate dialect approach or the eclipselink counterpart. By doing this the big communities and joint resources of both projects could be used. Problem: Both projects consider their dialects internal ...


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2012, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo