I've been playing around with Spring+Hibernate with an hsqldb database. If you want to run hsqld standalone, you need to specify the URL in the form:
jdbc:hsqldb:file:/full/path/to/database/directory
As this is obviously not something I'd want to 'hard code', I thought I'd try to use a path relative to the home directory, as contained in the system property 'user.dir'. So, in the datasource section of my applicationContext.xml, I tried the following:
<property name="url">
<value>jdbc:hsqldb:file:${user.dir}/WEB-INF/db/db</value>
</property>
Unfortunately, when I tried to use this URL, it showed up without any replacement, i.e., as:
jdbc:hsqldb:file:${user.dir}/WEB-INF/db/db</value
Is there something else I have to do?


Reply With Quote