-->
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: Can HQL generate SQL Contains statement
PostPosted: Fri Jul 16, 2010 2:46 pm 
Newbie

Joined: Fri Jul 16, 2010 2:43 pm
Posts: 2
I'd like to use Contains() instead of LIKE to improve text searching performance, but I could not make HQL to generate the SQL contains statements, is there a way doing this? without using native SQL...


Top
 Profile  
 
 Post subject: Re: Can HQL generate SQL Contains statement
PostPosted: Sun Jul 18, 2010 6:39 pm 
Hibernate Team
Hibernate Team

Joined: Fri Oct 05, 2007 4:47 pm
Posts: 2536
Location: Third rock from the Sun
did you look into Hibernate Search ? you might love it for this use case, especially if you're interested in performance, but there are other good reasons.

I don't think contains could be part of HQL, as I don't think that's implemented by many databases so it would be hard to support on all of them.

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


Top
 Profile  
 
 Post subject: Re: Can HQL generate SQL Contains statement
PostPosted: Mon Jul 19, 2010 9:47 am 
Newbie

Joined: Fri Jul 16, 2010 2:43 pm
Posts: 2
s.grinovero wrote:
did you look into Hibernate Search ? you might love it for this use case, especially if you're interested in performance, but there are other good reasons.

I don't think contains could be part of HQL, as I don't think that's implemented by many databases so it would be hard to support on all of them.


I know Hibernate Search, too bad I can't use it for the current project, stuck with Oracle text. I guess I got to build native SQL, instead of HQL.


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.