-->
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.  [ 2 posts ] 
Author Message
 Post subject: Discriminator tag not allowed in subclass tag
PostPosted: Mon Jun 12, 2006 1:24 pm 
Beginner
Beginner

Joined: Wed Oct 05, 2005 2:08 pm
Posts: 23
I've inherited a database schema that maps an inheritance heirarchy to one table using a discriminator column. No problem right? Yes, unfortunately.

The designer has chosen to use the discriminator for the first level of inheritance. Then each subclass uses it's own discriminator field for the next level of inheritance. If NHibernate allowed a discriminator tag in the sub class tag, this would be no problem. Unfortunately, it does not appear that this is the case - when I serialize my mapping attributes it does not render my discriminator tag in my sub class tag. Is this a limitation of NHibernate or the mapping attribute serializer. Any suggestions on how to map this?

Is the normal approach for all sub-subclass to use the same discriminator field as the sub class? If so, Is Nhibernate smart enough that if I query for a subclass it returns all the subsubclass instances?

Thanks very much and keep up the good work,
Jafar


Top
 Profile  
 
 Post subject: Same problem.
PostPosted: Mon Jun 19, 2006 5:56 am 
Newbie

Joined: Wed Apr 19, 2006 3:36 am
Posts: 2
I have the same problem.

I think that this is a possible bug of NHibernate. Have you try report it as a bug?

Regards.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 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.