1

I am having some trouble searching for what I want to do. I am told that I can generate database tables using Hibernate that represent POJOs I created in Java. I must be missing something. Thank you for the help on the trivial issue.

user1281598
  • 217
  • 4
  • 17

1 Answers1

1

Add this property in your configuration file

<property name="hibernate.hbm2ddl.auto">create</property>
Ramesh Kotha
  • 8,266
  • 17
  • 66
  • 90
  • Then once I run the Spring/Hibernate web project once, the tables should automatically be created, but not overwritten the second time the application is run, correct?
    Further more, are any annotations required when creating the POJOs or any restrictions on the data types used, as in Sets, Arrays, Maps etc?
    – user1281598 Jun 29 '12 at 17:57