java - EclipseLink and H2 -


i trying use eclipselink jpa provider h2 dbms in eclipse ide.

when create new jpa project , fill data (url="jdbc:h2:~/test",username="user",password="") connection type : resource local (i'm using embedded mode) 2 odd things :

  1. when try create entities table blank table list
  2. i error message near @entity notation saying "catalog user can't resolved entity e1" or "schema user can't resolved entity e1" depending on keeping default value catalog or changing upon project creation user database user name

the database contains tables using h2 console in firefox

what cause of these problems , how can solve , have page or book can persistence.xml file (other oracle official web site)?

eclipselink doesn't create database tables you, unless explicitely tell so.

the way described in the documentation

eclipselink can used automatically generate tables , database schema persistence unit. done through "eclipselink.ddl-generation" persistence unit property, set either "create-tables" or "drop-and-create-tables". tables , constraints generated of classes defined in persistence unit.


Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -