Generic H2 Configuration Gone

51 views
Skip to first unread message

pr1

unread,
Sep 26, 2019, 4:48:02 PM9/26/19
to H2 Database
Hello,
I've mistakenly deleted the Generic H2 Configuration in the Web Console on Windows.
Reinstalling H2 hasn't brought it back.
Any help would be much appreciated.
Many thanks.
pr1

Evgenij Ryazanov

unread,
Sep 26, 2019, 8:41:12 PM9/26/19
to H2 Database
Hello.

You can type a some name of the setting, org.h2.Driver as a driver, your JDBC URL and user name and save such custom setting. Predefined settings aren't intended to be used as is, they are just templates.

Another solution is to edit the configuration file.

The configuration is stored in the file .h2.server.properties (note the leading dot) in your home directory.

You can create them by appending
SOME_NUMBER=Generic H2 (Embedded)|org.h2.Driver|jdbc\:h2:~/test|sa
SOME_NUMBER
=Generic H2 (Server)|org.h2.Driver|jdbc\:h2\:tcp\://localhost/~/test|sa
Replace SOME_NUMER with some real numbers, presets with higher number are listed at the first positions.

If you don't have any custom settings in this file, you can also delete it, it will be recreated with default settings on startup of the H2 Console.
Reply all
Reply to author
Forward
0 new messages