openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anthony Alba <ascanio.al...@gmail.com>
Subject OpenJPA+H2: accidentally finds table USERS from INFORMATION_SCHEMA instead of PUBLIC
Date Tue, 17 Nov 2020 05:25:01 GMT
I am using an Entity called User, with the table "Users".

Unfortunately, without DDL scripts and using metadata only DDL in
persistence.xml
for drop-and-create, OpenJPA is finding the USERS table from the
INFORMATION_SCHEMA,
instead of the PUBLIC schema (where the table does not yet exist).

As a result it does not send the "CREATE TABLE" SQL and tries to alter
the non-existent
USERS table with "ALTER TABLE" (since SQL statements target the H2
PUBLIC schema).

Hibernate: it does not detect any USERS table in PUBLIC schema and so sends
"CREATE TABLE" DDL.

Is this a "bug" ?

Cheers
Anthony

Mime
View raw message