db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dyre.Tjeldv...@Sun.COM
Subject Re: embedded apache derby on Windows connection URL
Date Fri, 16 Sep 2005 14:29:28 GMT
The following message is a courtesy copy of an article
that has been posted to comp.lang.java.databases as well.

supermail99@fastmail.fm writes:

> I'm having trouble creating a proper Java connection URL for an
> embedded apache derby database on Windows. My database folder was
> created with ij and is located at
> C:\mytestdb
> In my program the following line yeilds the error
> SQL Exception: Database 'mytestdb' not found.
> Connection
> conn=DriverManager.getConnection("jdbc:derby:C:///mytestdb");
> What is wrong with this URL?

I don't use Windows, but on Linux I can say

and I think that jdbc:derby:c:/mytestdb will work on windows

(section Database Connection Examples)

> or, if I use the connection string "jdbc:derby:mytestdb", what is the
> search path?

It's relative to the property derby.system.home
(see the section about properties)


View raw message