-->
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.  [ 1 post ] 
Author Message
 Post subject: joined-subclass inside subclass
PostPosted: Mon Feb 14, 2005 10:40 am 
Newbie

Joined: Wed Sep 29, 2004 10:45 am
Posts: 6
I have read some topic about multitable mapping in this forum. I understand Hibernate3.0 gives the <join> feature to solve the problem. Somehow, my problem is kind of different.

I have

Class B implements Interface A ---> Table X
Class C extends Class B --- Table Y


In the tables, I am using the primary key column as my discriminator column which value is "not null"

I am using Criteria API. My query object is A.

I have following mapping for A and B.

<hibernate-mapping package="gov.nih.nci.cabio.domain">
<class name="A" table="X">
<id name="id" ...>
<generator class="assigned" />
</id>
<discriminator column="a" insert="false"/>
<subclass name="B">
<property name="title" ..../>
...
...

</subclass>
</class>
</hibernate-mapping>

To add the mapping for B and C, the join doesn't work for me. Is there any solutions?

Thanks,
zeng


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

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.