We hava a rather bizarre architecture here that splits the persistence layer into several modules, each with it's own mappings.
These modules are layered, meaning that my module depends on another module (that does not depend on mine) and both modules have their own mapping files.
My mapped objects have relations to the other modules' mapped objects, so I have to include these (foreign) mapping files in my Hibernate configuration.
So far, so good. But when I want to generate the schema using hbm2ddl I have to include these foreign mappings, too. Otherwise my mapping is incomplete.
But I just don't want that the generated script includes statements that affect the foreign layer. I just want a script that includes *my* tables.
Is there any way to achieve this ?
|