-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: mixing of inheritance strategies in 3.0
PostPosted: Fri Jan 07, 2005 12:27 pm 
Newbie

Joined: Wed Aug 04, 2004 6:19 am
Posts: 9
[b]Hibernate version: 3.0a[/b]

I want to mix two inheritance strategies in Hibernate 3.0a.
I have four classes

A,
B extends A, using joined-subclass
C and D extend B, using subclass with a discriminator column

A will map to table TA
B,C,D will map to table TB.

According to the 3.0a documentation:
Hibernate does not support mixing <subclass> mappings and
<joined-subclass> mappings inside the same <class> element. However,
it is possible to use a <join> element to map this.

this should be possible.
But I have no idea how to do this.
My simple solution didnt work. complaining about:
discriminator is not valid in joined-subclass.

Any help would be appreciated.

Yours,
Martin


Top
 Profile  
 
 Post subject:
PostPosted: Fri Jan 07, 2005 3:20 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
look in the junit tests for examples

_________________
Max
Don't forget to rate


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 11, 2005 3:54 am 
Newbie

Joined: Wed Aug 04, 2004 6:19 am
Posts: 9
Thanks,

hibernate-3.0\test\org\hibernate\test\join

helped me.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.