db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From BeNdErR <bendertheoffender...@hotmail.com>
Subject Re: Derby : No suitable driver found for jdbc:derby:db;create=true
Date Thu, 02 Dec 2010 15:35:37 GMT

I modifyed as you told me, that's the error print I get in the client window:

SQLState:08001
Error Code:0
Message:No suitable driver found for jdbc:derby:db;create=true


The rmid window, for the activatable server, shows this error:


Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:out: DBMS.java
ClassNotFoundException Error: org.apache.derby.jdbc.EmbeddedDriver
Thu Dec 02 16:22:34 CET
2010:ExecGroup-0:err:java.lang.ClassNotFoundException:
org.apache.derby.jdbc.EmbeddedDriver
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.net.URLClassLoader$1.run(URLClassLoader.java:202)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.security.AccessController.doPrivileged(Native Method)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.net.URLClassLoader.findClass(URLClassLoader.java:190)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.lang.ClassLoader.loadClass(ClassLoader.java:307)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.lang.ClassLoader.loadClass(ClassLoader.java:248)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.lang.Class.forName0(Native Method)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.lang.Class.forName(Class.java:169)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
tmp.DBMS.<init>(DBMS.java:24)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:out:Apro la connessione con il DB.
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
tmp.AuthServer.register(AuthServer.java:79)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.lang.reflect.Method.invoke(Method.java:597)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:305)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.rmi.transport.Transport$1.run(Transport.java:159)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.security.AccessController.doPrivileged(Native Method)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.rmi.transport.Transport.serviceCall(Transport.java:155)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:535)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:790)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:649)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
Thu Dec 02 16:22:34 CET 2010:ExecGroup-0:err:	at
java.lang.Thread.run(Thread.java:662)

the first error is thrown when he enters the DBMS constructor. In the setup
code of the activatable server I used this setting to tell him where he can
find *.class he needs:
prop.put("java.class.path", "/home/user/app/lib/");
because rmid does not accept a -classpath option, I assume that putting the
classpath into the code is an alternative method..
I never mentioned before this error because, sincerely and stupidly, I never
watched the rmid window, focusing only on the client error.

I have a question: does the fact that I run every piece of the app (server,
rmid, client) in different shells? I mean, running (or trying) derby in one
shell, lets the others interact with it?
Another question: my scope is to build this app with a database, then move
ALL the codes into another pc, without installing derby (I can't because on
that pc I'm not the admin). I thought was enough to move all the derby
libraries in a folder, and then run everywhere I need my application.. Am I
all abroad?

Hoping I'm not wasting your time in a useless thing, thanks a lot
-- 
View this message in context: http://old.nabble.com/Derby-%3A-No-suitable-driver-found-for-jdbc%3Aderby%3Adb-create%3Dtrue-tp30335341p30359597.html
Sent from the Apache Derby Users mailing list archive at Nabble.com.


Mime
View raw message