| I noticed that since version 5.1.4 the entities wouldn't be updated anymore (with hibernate.hbm2ddl.auto=update) when adding fields. It probably applies to Oracle and not to MariaDB, because of HHH-11023. I attach a test case which isn't exactly a test case, but you can see the difference between 5.1.3 and 5.1.4 in the logs and on the database. It seems that entities are not updated but re-created instead (they exist and so re-creation fails):
Steps to reproduce
- If using my test case (not really a test case), create an Oracle schema and change persistence.xml accordingly
- Create an entity (for example IwillUpdate in my test case) with FIELD1.
- Launch the entityManager (for example in the JPAUnitTestCase).
- Verify that the table has been created with FIELD1
- Add a FIELD2 in the entity
- Launch the entityManager again
- Verify that you have a ORA-00604 error in the log and that the table hasn't changed (no FIELD2)
- change hibernate version to 5.1.3 in the pom.xml
- Launch the entityManager again
- Verify that no error is shown and that the table has been updated
|