Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Generate schema from entities using JPA2 + Hibernate + Eclipse 4.2 + MySQL 5.5

I am new to Hibernate/JPA and I am stuck at what I think is the last step. I have created a schema in my MySQL instance and want to generate the tables for the schema from the JPA entities I have created. I get an option in JPA Tools in eclipse "Generate Tables from Entities" but that gives me a message "Generate Tables from Entities is not supported by the Generic Platform. Is there a plugin or tool I need to use to make this work ?

like image 378
Vineet Avatar asked Oct 11 '12 06:10

Vineet


1 Answers

You will need to first install Hibernate Tools - How to install Hibernate Tools in Eclipse?

Then go to Project->Preferences->JPA and change the Platform to the appropriate version of Hibernate instead of the Generic Platform.

like image 179
Karen Butzke Avatar answered Mar 02 '23 00:03

Karen Butzke