Maven 1.x Hibernate Plugin

hibernate:schema-update does not delete tables

Details

  • Type: Bug Bug
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: 1.3
  • Fix Version/s: None
  • Component/s: None
  • Labels:
    None
  • Environment:
    WinXP(SP2), JDK 5.0, Maven 1.0.2
  • Number of attachments :
    0

Description

The first time hibernate:schema-update is run, it works fine. However, if the *.hbm.xml files are modified so that one of the original tables no longer exists, a subsequent run of hibernate:schema-update does not remove that table. Seems like an "update" should make sure the DB's schema exactly matches what is specified by the *.hbm.xml files.

Activity

Hide
Jamie Bisotti added a comment -

Anyone? Anyone?

Show
Jamie Bisotti added a comment - Anyone? Anyone?
Hide
Dan Tran added a comment -

It is hibernate's issue. Check out the hibernate site

Show
Dan Tran added a comment - It is hibernate's issue. Check out the hibernate site
Hide
Brill Pappin added a comment -

I very much hope that it never removes tables and dumps data... or at least if it ever has the option, it's off by default.
When I do a schema update, I do not expect data to vanish in fact that would make ting difficult during development because I wouldn't be able to migrate the old data to the new structure.

If you want to tables removed, use schema-export and you'll get exactly what you expect.

Show
Brill Pappin added a comment - I very much hope that it never removes tables and dumps data... or at least if it ever has the option, it's off by default. When I do a schema update, I do not expect data to vanish in fact that would make ting difficult during development because I wouldn't be able to migrate the old data to the new structure. If you want to tables removed, use schema-export and you'll get exactly what you expect.

People

Vote (0)
Watch (2)

Dates

  • Created:
    Updated: