-->
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: Problem using <joined-subclass> + <filter>
PostPosted: Sat May 17, 2008 6:45 am 
Newbie

Joined: Sat May 17, 2008 6:33 am
Posts: 1
Hello,

I am using NHibernate now the second time in a project and it happens now, that I am running into deep problems with it - at least, it seems.

I have the following problem:

I have an inheritance mapping. A Person is the superclass. A User derives from Person and Kunde derives from User. ( Person < User < Kunde )

The mapping itself works fine, also saving, updating, inserting and deleting of data works fine.

But I am experiencing great problems when using filter. When using the <filter> and <filter-def> elements on Person, everything works fine. But when I want to filter a "Kunde" by its defined properties, I am getting the error, that <filter> definitions cannot be done in <joined-subclass>.

When I am trying to insert the <filter> and <filter-def> elements for the properties of a "Kunde" into the Person.hbm.xml file, NHibernate generates the wrong SQL statements, 'cause it thinks, that the properties I am going to filter are part of the Person table.

How can I solve this problem without any dirty hacks?

Hibernate version: 1.2.1

Name and version of the database you are using: SQL Server 2005 Express

If someone wants me to add some code in here, please feel free to ask.

Kind regards,
Harald


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.