0
votes

Our project uses Lucene.net for full text search. In IndexSearcher we use MultiFieldQueryParser with some fields. For example:

 var parser = new MultiFieldQueryParser(Version, new[] { "ArtNo", "Name", "Description" }, analyzer);

I have a problem with returned results. Lucene sorts them by Sort.RELEVANCE from all fields. But I need that results by field 'ArtNo' must be first then 'Name' and etc, set priority for fields. How to do that trick?

1

1 Answers

0
votes

Sorting options are specified in IndexSearcher and not in Query nor QueryParser. You should be able to find searcher being initialized just a few lines below.