I'm trying to map a legacy table design into hibernate and I'm running into a problem where I have two tables that are logically sub classes of an abstract superclass. I tried using MappedSuperclass but I've found that I have other tables refering by id(its unique across both tables) back to that abstract superclass, and you can't have an association pointing to a MappedSuperclass.
I'm now trying to use table per class inheritance but @AttributeOverride doesn't work there and there are fields in the tables that have different column names but have the same logical meaning. I'd like to have it mapped in the parent class and only the column names set in the sub classes.
Is there a way to do essentially the same thing as @AttributeOverride when doing table per class mapping, or some way to have an association to a MappedSuperclass?
|