Liferay 6: default database : HSQL

When you first get the Liferay bundle, the database configured by default is HSQL (Hyper SQL).

It’s a very simple database engine that could be either in-memory or disk based. In the Liferay bundle it’s configured to be used as a disk based database.

The database files are located at “<liferay home folder>/data/hsql/portal” (default value).

Some data already exists in this DB, it lets you have a running Liferay instance once the Liferay bundle downloaded.

JDBC configuration in Liferay bundle

The JDBC configuration could be found in the file portal.properties:

jdbc.default.driverClassName=org.hsqldb.jdbcDriver
jdbc.default.url=jdbc:hsqldb:${liferay.home}/data/hsql/lportal
jdbc.default.username=sa
jdbc.default.password=

How to manage your HSQL database

A very simple tool is provided in “hsql.jar”, it lets you basically manage your database (querying, tables creating/altering, …). You JAR file is located in your Liferay bundle.

You will surely love it, it’s a Java Swing application! 🙂

To launch it, execute the following command:

java -cp hsql.jar org.hsqldb.util.DatabaseManagerSwing

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s