H2 Database Engine


Can anyone tell me if its possible to use the JDBCConnectionPool with the H2 Database engine in order to use TableQuery


Hi Douglas,
did you find out how? I managed to make it work for retrieving records from the db, but inserts don’t work for me.

You would probably need to implement a custom H2Generator that creates the query and update strings used. See the default generator and the customized subclasses for MSSQL and Oracle in the package com.vaadin.data.util.sqlcontainer.query.generator . The class might be very simple if there are not too many peculiarities in H2 SQL syntax.

Don’t forget to give the custom generator as a constructor parameter to TableQuery.

If you implement this, I believe also others might be interested in it so you could consider publishing it in the