Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Executable jar app doesn't find Driver

 
juliane gross
Ranch Hand
Posts: 161
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I built an application with embedded Derby (cloudscape) database.
It runs fine as long as I don't try to make a executable JAR file.
Then I get this error message:
java.lang.ClassNotFoundException: org.apache.derby.jdbc.EmbeddedDriver

(The program parts which don't use the database still run fine).
Derby (cloudscape) needs the derby.jar to find its EmbeddedDriver.

How can I tell my jar'ed app where to find the Driver? Do I have to
put derby.jar in a special place in my app's jar file structure?
Or redo my classpath somehow? (But why, if derby.jar is found by
my app in a not-jar'ed way?)

I am very glad about any tips and help,
thank you!
Juliane
 
Stefan Wagner
Ranch Hand
Posts: 1923
Linux Postgres Database Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That's a jar-question, not a jdbc-Question.
And it's answered over and over again. (search beginners or intermediate: jar)
 
juliane gross
Ranch Hand
Posts: 161
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you, Stefan.

For anybody else having this problem:
I found the answer in the Java advanced forum

here

it was a problem with the manifest file.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34401
346
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Juliane,
I'm glad you found the answer. I'm going to move this over to Java In General so people searching can find it better.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic