db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tim Watts <...@cliftonfarm.org>
Subject Re: ClientDriver class not found in derby.jar
Date Sat, 08 Oct 2011 14:30:50 GMT
You need to put derbyclient.jar in your classpath. You probably don't
need derby.jar if your class is just acting as a client. You would need
that one if you're using Derby as an embedded database.


On Sat, 2011-10-08 at 14:00 +0530, Pramod Talekar wrote:
> Hello,
> 
> 
> I'm using Derby-10.8.1.2 bin installation for use in my program, 
> 
> 
> I got the following error stack :
> 
> 
> java.lang.ClassNotFoundException: org.apache.derby.jdbc.ClientDriver
> at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
> at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
> at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
> at java.lang.Class.forName0(Native Method)
> at java.lang.Class.forName(Class.java:169)
> at TestDB.getConnection(TestDB.java:77)
> at TestDB.runTest(TestDB.java:25)
> at TestDB.main(TestDB.java:16)
> 
> 
> 
> 
> for this code segment :-
> 
> 
> try {
> Class.forName("org.apache.derby.jdbc.ClientDriver");
> System.out.println("Registering with the driver");
> 
> } catch (Exception e) {
> // TODO: handle exception
> e.printStackTrace();
> }
> 
> 
> Please advise.



Mime
View raw message