Hibernate version: 3.2.6
Hi everyone,
I've tried to find a solution on the forum, there are a lot of enum discussions but i didn't find what I'm looking for.
We have an existing dataBase with lots of tables representing enum, (customerType, productType, ...) which we are integrating with hibernate.
for example, the customer table has a Long field "customerType" which is a foreign key to the CustomerType table.
I would like to move those tables to Java Enum but I have a few questions :
- Is there a way to keep my tables for direct SQL report but having a clean design a not having to synchronize my enum to those tables manually everytime we update the enum ?
I don't really like the idea of having unused tables (at least from the java code) but i don't see many of options and I think Enum would be better, isnt it ?
Thank you.
|