This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 78212 - "Unable to find driver." error, but the derby driver can be seen
Summary: "Unable to find driver." error, but the derby driver can be seen
Status: RESOLVED FIXED
Alias: None
Product: serverplugins
Classification: Unclassified
Component: Sun Appserver 9 (show other bugs)
Version: 5.x
Hardware: All All
: P2 blocker (vote)
Assignee: Nitya Doraisamy
URL:
Keywords:
: 78178 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-06-18 00:22 UTC by _ ludo
Modified: 2006-06-27 08:13 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description _ ludo 2006-06-18 00:22:43 UTC
My private latest build:

I can connect to the sample db from runtime and view the data of the customer
table, so the driver is registered (I can see the 2 for derby).
Then, using the Entity from DB wizard, when I select the jdbc/sample in the
datasource, I get an error dialog with 
"Unable to find the driver."
message. So I am stuck...
Nothing logged on the console.
Comment 1 _ ludo 2006-06-18 04:52:38 UTC
sync up with Nitya on this. I had 2 datasources registered on the server.
I created a new empty db for jbosssword via the IDE, and it was also registered.

I've seen this error with PetStore registered as well at JBossWorld both machine.
When I resinstall everything, I do not see it, sit it might be linked to
multiple resources on the server.
Comment 2 Andrei Badea 2006-06-19 08:46:06 UTC
*** Issue 78178 has been marked as a duplicate of this issue. ***
Comment 3 Andrei Badea 2006-06-19 08:51:55 UTC
I debugged this once and JDBC driver class returned by the data source was not
the driver class, but the data source class. So it could be a problem in the
appserver plugin where mapping between data source and driver classes is not
done correctly in some cases. Reassigning to Nitya for evaluation.
Comment 4 Andrei Badea 2006-06-26 09:27:47 UTC
Another user report, this time with the Oracle driver:

http://www.netbeans.org/servlets/ReadMsg?list=nbj2ee&msgNo=3201
Comment 5 Nitya Doraisamy 2006-06-27 00:24:08 UTC
The plugin was using DatabaseConenction to obtain deriver information. In some
cases, when the connection is mising or disconnected, this is null. Instead now
there is a mapping in the plugin to handle conversions from datasourceclassname 
to driver name.
Comment 6 Andrei Badea 2006-06-27 08:13:00 UTC
Driver information (the return value of DatabaseConnection.getDriverClass())
should never be null and should not depend on the connection state. If you have
steps leading to a null value from this method please file an issue against db/code.