michael nesterenko
michael nesterenko

Reputation: 14439

h2 database home

I was looking into derby database and found property which sets derby home directory.

Are there property in h2 database like to derby.system.home to set home directory?

Upvotes: 2

Views: 1189

Answers (1)

Thomas Mueller
Thomas Mueller

Reputation: 50087

Yes, H2 supports the system property h2.baseDir, even thought I wouldn't actually recommend using it. Instead, I suggest to use either a hardcoded path in the database URL, such as jdbc:h2:/data/dbs/test or use a path relative to the user home directory, such as jdbc:h2:~/dbs/test.

Upvotes: 1

Related Questions