mathpere / grails-hibernate-search-plugin

Integrates Hibernate Search features to Grails
http://grails.org/plugin/hibernate-search
Apache License 2.0
21 stars 18 forks source link

Fultext Search #39

Closed franciscoingreen closed 6 years ago

franciscoingreen commented 6 years ago

Can u post a example for do a Fulltext search?

In project example, i see the use of wildcard to search, but can i use like this? MyDomainClass.search().list{ "word to search in all indexed fields" }

lgrignon commented 6 years ago

Did you read the README? Please see here https://github.com/mathpere/grails-hibernate-search-plugin#mixing-with-criteria-query a simple example using fuzzy search (just remove the join part). Anyway you have to specify on which property you want to filter, the code you provide in your question doesn't include any.

franciscoingreen commented 6 years ago

Did you read my question? My question was exactely about search in all indexed properties without specify one!

lgrignon commented 6 years ago

Ok. Sorry I didn't read the string's content. Then no, it is not possible the way you suggest, you have to specify properties. That being said, I think you can call a getIndexedProperties() on the object returned by MyDomain.search() (please see HibernateSearchApi for comprehensive reference). If you ever want to contribute to add the behavior you describe, please file a PR, I would definitely review it. Please close issue if it answers your question. Bye

franciscoingreen commented 6 years ago

Perfect, solved using getIndexedProperties()!