Andrii Soloviov
Andrii Soloviov

Reputation: 1

I'm using solr for address searching and I get different results depends on word order

Is this correct behavior or do I need to do some extra setting?

I created custom filter where remove special characters and add synonyms

Upvotes: 0

Views: 81

Answers (1)

Jokin
Jokin

Reputation: 4218

the search in Solr is a two step process, first the documents are matched, and second they are scored for ordering the results. The scoring takes in account how near are one term to the other, so if the order of the words in the query change, the scoring is affected.

if you omit the storing of word positions with omitPositions="true" in the field definition, and then the search should not be affected by the word order. In the Solr fields documentation you have many more options and how they affect the search described.

Upvotes: 1

Related Questions