Ok,
But the thing is: on Netbeans, when creting a new project (lets say that
I already have created the database)
I do the following:
Choose Project -> Java -> Java desktop Application -> NEXT.
And then I choose Database aplication.
On the next screen I need to choose the database. And I want it to be
embedded.
What steps should I take ?
Thanks
On NetBeans 6.0
Kai Ponte wrote:
On Thursday 27 March 2008 12:34:50 pm bruehlicke wrote:
I let let user pick a directory (either via a property or via a file
selector) than I set the derby.system.home property programtically like
System.setProperty("derby.system.home", dbLocation);
The value of dbLocation when you print it is for ex. C:\Documents and
Settings\fred\xyz (that is the way you should set the value) but when you
use the debugger it will of course show up as C:\\Documents and
Settings\\fred\\xyz
After this value is set I use the URL like jdbc:derby:myDB;create=true
and the database myDB is created under the given directory.
Hope this helps
B-)
That would work out well.
On my apps, I usually place the database - and various config files - in a
folder under the user's home folder.
I have line -
File strHomeFolder = new File ( System.getProperty("user.home") + "/.MyApp");
I then append a database folder under this for the database.
In any case, when I'm downgrading to legacy operating systems that still use
drive letters like Wintendo - I have one vista, one Xp and one win2K
machine - I do the followng
jdbc:derby:C:\Path\To\data
HTH!
--
========================================================
Ricardo José da Silva Seromenho
Aluno 23842 Universidade do Algarve, Campus de Gambelas
e-mail: [EMAIL PROTECTED]
web: http://www.deei.fct.ualg.pt/~a23842/