java - How can I connect with an SQL tool to an embedded h2 db? -


i have simple h2 database example, assume database stored in single file. find file? i'd connect db using sql clients squirrel. file placed default?

    <property name="eclipselink.jdbc.platform"         value="org.eclipse.persistence.platform.database.h2platform" />     <property name="javax.persistence.jdbc.driver" value="org.h2.driver" />     <property name="javax.persistence.jdbc.url" value="jdbc:h2:~/mydb;file_lock=no" />     <property name="javax.persistence.jdbc.user" value="sa" />     <property name="javax.persistence.jdbc.password" value="sa" /> 

based on following value:

jdbc:h2:~/mydb;file_lock=no" 

it appears database file located in home directory in file called mydb

the ~ denotes home directory.


Comments

Popular posts from this blog

c++ - CryptStringToBinary API behavior -

java.util.scanner - How to read and add only numbers to array from a text file -

iphone - Three second countdown in cocos2d -