lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Romiko Derbynew <Romiko.Derby...@readify.net>
Subject Lucene Query Parser
Date Mon, 28 Nov 2011 04:17:52 GMT
Hi Guys,

I am using Lucene with Neo4j. Currently I have queries working well with a combination of
Exact and Fuzzy matches in one query.

However, we desire a report that first takes the ranking and boosting as the highest priority,
but then we want to sort my first name and last name, and always have the highest ranks on
top. I cannot find a way to do this with the Query Parser API (http://lucene.apache.org/java/2_9_1/queryparsersyntax.html),
is this the case, or do I have to succumb to by passing the query parser API and executing
a custom sort via groovy on Neo4j?


Current Query sample:
"+(FamilyName:smith*^8 FamilyName: smith *~^8 GivenName: smith *^2 GivenName: smith *~^2)


So if I get these result
Nadia Smith (This was on top as it was first entry in the index)
John Smith
Smith Michaels
Smith Marks
Adam Smith
Bob Smath

I want it to then sort by first name and then by last name, but keep the highest ranks at
top.
Adam Smith
Nadia Smith
John Smith
Smith Marks
Smith Michaels
Bob Smath

Thanks in advance for any advice.



---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-user-help@lucene.apache.org


Mime
View raw message