Quote:
I read that table per concrete class inheritance should be avoid if there is an association from role to A as in your case.
Where did you read that? And what is the reason given?
The only 'problem' I know is with the ability (or lack thereof) of hibernate to create FKs and not null constraints. But I wouldn't rate those to high, and the problems can be solved in many cases by custom constraints (at least with Oracle)
if you don't go with single table inheritance but with inheritance per class you would get
- one table for Role containing the common attributes (at least the reference to A)
- one table for B and C each, containing the unique attributes of each class
If you where referring to the actually mapping (Annotations / xml) I have to refer to the documentation.