javamysqldatabasehibernate

Hibernate hbm2ddl.auto default value


What is the default value of hibernate.hbm2ddl.auto in the hibernate cfg file mapping? Is it possible to remove

<property name="hibernate.hbm2ddl.auto">update</property>

from the config file? If I remove this property will it affect my DB???


Solution

  • Automatically validates or exports schema DDL to the database when the SessionFactory is created. With create-drop, the database schema will be dropped when the SessionFactory is closed explicitly.

    validate | update | create | create-drop