db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel John Debrunner <...@apache.org>
Subject Re: Specifying the Derby Database Location
Date Wed, 01 Feb 2006 18:51:11 GMT
Manjula G Kutty wrote:

> Afkham Azeez wrote:
>> Hi Folks,
>> I have my derby.properties file in $MY_PROJECT/conf directory. This is
>> the directory pointed to by the derby.system.home System property. But
>> no my database is getting created under $MY_PROJECT/conf e.g. as
>> I need my database to be created as $MY_PROJECT/DATABASE. Is there a
>> property I can specify in the derby.properties file which will specify
>> the physical location of the Database?

This is a good candidate for a Derby FAQ.

Database names in Derby are more than a single word, they are URL like
in that they can include the URL path separator character forward slash '/'.

A database name is either relative or absolute.

An absolute path corresponds to an absolute path on your file system:


   top level folder for the database is


  top level folder for the database is

A relative path is relative to the value of the system property
derby.system.home if it is set, otherwise relative the current working
directory of the java virtual machine.

All these examples are different ways to connect to the cdcollection
database described above, examples on windows would be similar,
including use of the forward slash.



  current working directory = /home/fred

  current working directory = /home/fred/databases/projects


View raw message