db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "A. Rick Anderson" <ar...@pobox.com>
Subject Eclipse Plug-in Lab code is failing to find driver in derby.jar
Date Sat, 17 Feb 2007 02:38:46 GMT
I'm getting a "driver not found" exception when running a relatively 
trivial derby program from within eclipse.  It's frustrating because I 
can crack the derby.jar file and the targeted driver class is in the 
derby.jar file that is in the build path for the project.

The targeted driver is "Borg.apache.derby.jdbc.ClientDriver" and it's 
found in the derby.jar file that is the first library on my build path.

I'm going through the Eclipse plug-in labs in order to get a baseline 
"Hello World" environment validated when I encountered this error.

With the fix I got the other day, things were going great.  I 
successfully ran the procedures that create the stored procedures and 
test them (stored_procedures.sql, and execute_sp.sql).  This tells me 
that the DB server is running on my local server at the port expected.

When I take it to the next level and run the actual Java application 
"Jays.java" that I see any problems.  Stripping it down to the simplest 
code, I get the following:

private static final String derbyClientDriver =
private static final String derbyClientURL =

public static void main(String[] args) throws Exception {
     runDriver(derbyClientDriver, derbyClientURL);
} // method main

private static void runDriver(String driverName, String driverURL)
     throws ClassNotFoundException, SQLException, Exception {
     Connection conn = DriverManager.getConnection(driverURL); // dies
} // method runClientDriver

A. Rick Anderson

View raw message