-->
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: Search associated Entities
PostPosted: Thu Nov 03, 2011 7:00 am 
Newbie

Joined: Thu Nov 03, 2011 5:54 am
Posts: 1
Hi experts,

i have two entites associated with many to one. I need to search them via the relation and i need to search them in an single query.

Everything is fine when i set the first entity to @Indexed an the relation as @ContainedIn and @IndexedEmbedded (But i cannot search directly the second entity). But the search fails if i add the @Indexed annotation to the second entity, in order to search this one directly. I am facing the Exception:
Caused by: java.lang.IllegalArgumentException: Can not set java.lang.Long field com.my.package.idclassA.id to com.my.package.idclassB

Assume that we are using composite id implemented in id classes. I did some research via google on my own but i could noch figure out what the problem is.

Does it matter that we defined the relationship in xmls?

thanks for any help,

Rene


Top
 Profile  
 
 Post subject: Re: Search associated Entities
PostPosted: Mon Nov 07, 2011 5:45 am 
Hibernate Team
Hibernate Team

Joined: Thu Apr 05, 2007 5:52 am
Posts: 1689
Location: Sweden
Can you provide some code?


Top
 Profile  
 
 Post subject: Re: Search associated Entities
PostPosted: Mon Nov 07, 2011 9:26 am 
Hibernate Team
Hibernate Team

Joined: Fri Oct 05, 2007 4:47 pm
Posts: 2536
Location: Third rock from the Sun
Could this be related to https://hibernate.onjira.com/browse/HSEARCH-937 ?
Please paste the stacktrace.

_________________
Sanne
http://in.relation.to/


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.