H2 and Oracle Compatiability issues H2 and Oracle Compatiability issues oracle oracle

H2 and Oracle Compatiability issues


H2 doesn't recognize the syntax

VARCHAR2(32 BYTE)  

Change this to

VARCHAR2(32)

... and it will still work in oracle and will at least remove your first error in H2.


Short Answer

Oracle is a huge piece of software, and you can't expect a small embedded database to be 100% compatible.

Long Answer

Compatibility Modes

As documented, for certain features, this database can emulate the behavior of specific databases. However, only a small subset of the differences between databases are implemented in this way. This list is documented.

Compatibility

As documented, H2 is (up to a certain point) compatible to other databases such as HSQLDB, MySQL and PostgreSQL. There are certain areas where H2 is incompatible.

All database engines behave a little bit different. Where possible, H2 supports the ANSI SQL standard, and tries to be compatible to other databases. There are still differences however.