Boas Enkler
Boas Enkler

Reputation: 12557

Azure Search ranking cities by country (second search field)

For testing I've created a index with cities from the whole world. Each city has a name, a geolocation, a country code,....

With the following search

https://mySearchUrl.search.windows.net/indexes/cities/docs?search=York&api-version=2015-02-28

Would return York and New York besides other results.

Now i would like to define that results in the US (in this example assumed as user culture) should get higher rankings and should be more likely included then the uk results.

How can I do this?

So I should get New York more likely then just York. Is there a way to do this?

Upvotes: 0

Views: 135

Answers (1)

Eugene Shvets
Eugene Shvets

Reputation: 4671

you can accomplish this using scoring profiles feature of Azure Search, in particular tag boosting scoring function. For an example, see http://azure.microsoft.com/blog/2015/02/05/personalizing-search-results-announcing-tag-boosting-in-azure-search/. (BTW, although that link uses REST API, we have full support for scoring profiles in .NET SDK). HTH, Eugene

Upvotes: 2

Related Questions