db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bernt M. Johnsen" <Bernt.John...@Sun.COM>
Subject Re: read-only database in a web application?
Date Fri, 22 Sep 2006 13:17:59 GMT
David Harrigan wrote:
> Hi,
> 
> The ongoing learning adventure continues! :D
> 
> My database is built, now I've jar'ed it up thusly:
> 
> searchdb.jar
> 
> contains:
> 
> searchdb/seq0
> serachdb/seq0/......
> searchdb/log......
> searchdb/log/......
> 
> etc...
> 
> Now, I've dropped this jar into the WEB-INF/lib
> directory to make it available to my web application,
> 
> but when I try to open the database using this
> connection string:
> 
> jdbc:derby:/searchdb
> 
> I get back an exception saying it can't find the
> database /searchdb...
> 
> All libs in the WEB-INF/lib directory should be
> available to the application since the container
> makes them available on the classpath, so searchdb.jar
> should be on my classpath...

In your case the URL should read jdbc:derby:classpath:searchdb


-- 
Bernt Marius Johnsen, Database Technology Group,
Staff Engineer, Technical Lead Derby/Java DB
Sun Microsystems, Trondheim, Norway

Mime
View raw message