-->
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
PostPosted: Tue Apr 12, 2005 6:24 am 
Beginner
Beginner

Joined: Tue Mar 15, 2005 5:04 am
Posts: 26
Hallo,
ich habe zwei Klassen, die von der selben Klasse erben. Diese subklassen stehen beide in der selben Tabelle und unterscheiden sich durch den Discriminator. Wenn ich eine normale Abfrage auf die Klassen mache, bekomme ich auch wirklich nur die mit dem richtigen Discriminator.
Wenn diese Klasse aber in einem anderen Object in einem Set steht, lädt die Query aber trotzdem zusätzlich die Daten mit den Falschen Discriminatoren.
Was muß ich machen, damit es auch hier funktioniert?
Gruß,
TheAim

Hibernate version:3.0


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 12, 2005 7:18 am 
Beginner
Beginner

Joined: Tue Mar 15, 2005 5:04 am
Posts: 26
Hello,
don't know where my head has gone when I posted this thread. Here the englisch version.

I have two subclasses which store their data in the same table being diferentiated by the discriminator. When I query the two classes directyl, I receive the correct data with the correct discriminator.
But when these subclasses are in a set in another Class, the query ignores the Discriminator and sends all data. Data that does not belong to the subclass will be delivered within the subclass it does not belong to.
What do I have to do in the mappingclass to let the query take care of the discriminator?
Thx,
TheAim


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.