So, I have three entities in my schema, Person, Patient, and Doctor. Patient and Doctor both subclass Person, which is abstract. Also, Doctors have a one-to-many relationship with patients. I was just wondering what the best recommended mapping strategy would be for this situation. I'm looking for performance here, and will be performing many multi-join queries on this data (with the queries reaching out to other tables I'm not talking about here).
Initially I thought I should use table-per-concrete class, but I've read here:
http://docs.jboss.org/hibernate/stable/ ... le/#d0e849 that this strategy has lots of drawbacks. Also, I am sort of confused as to what the deal is with joined subclasses and if that is a strategy in itself and how that works, or if I need to declare the join points anyway, etc... Is it different from table-per-concrete subclass? Also, how is table-per-concrete class different than table-per-subclass?
In addition to all this, I need to do it using annotations, so if there are any stumbling blocks I should be aware of, it would be awesome if you let me know.
Thanks for your help