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: Question: Why are identifiers ignored in Example queries?
PostPosted: Wed Nov 16, 2005 11:14 am 
Newbie

Joined: Wed Nov 16, 2005 10:58 am
Posts: 5
I understand that the Hibernate reference states that "Version properties, identifiers, and associations are ignored". And I understand how to add associations. But I'd like to be able to use Example criteria even when the identifier is given.

Here's my situation. I'm currently using Example criteria for "search" queries. The user specifies search criteria, and the appropriate object graph is created to enable the creation of an Example criteria. But, the user has the ability to specify an identifier field as one of the search criteria.

Since the identifier is ignored in an Example criteria, I have to do the following:
if an identifier was specified
find by identifier
else
find by criteria

I'd like to better understand why the identifier is ignored on criteria queries, and if I'd be breaking anything else if I attempt to override this behavior.


Thanks,
-Mike Monette


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.