DDL generation and general persistence.xml settings (OpenJPA)

后端 未结 2 990
星月不相逢
星月不相逢 2021-01-05 03:46

Summary

I\'m trying to run a Java web application JPA 2.0 example. The example application was written to run in Glassfish, using

2条回答
  •  Happy的楠姐
    2021-01-05 04:24

    Foreign key constraints

    The next line does not create foreign keys:

    
    

    Only creates schema and deletes content of a database.

    But if you want create foreign keys, use the following lines:

    
    
    
    

    See generated SQL

    In another way, if you want to see the SQL output:

    
    

    NOTE: In order to see the generated output in the TomEE console, you need to change the log level in the file loggin.properties with openjpa.level = FINEST


    See more in http://openjpa.apache.org/faq.html

提交回复
热议问题