1

We have couple of sites configured under one Sitecore instance for different languages, for example one for "Australia(en-AU)" and one for "Korea(KR)"

We are using Azure search and observing when we are performing site search the results are doubled for Australia site(all contents in Sitecore have two versions- "en" and "en-AU") i.e getting results from "en" version and "en-AU" version both. This seems to be working fine for other language i.e Korea as an example.

Search expresssion has language code added to it as filter :

Sitecore.ContentSearch.Linq.Parsing.IHasNativeQuery.Query = {Search
expression: &search=language_1:(en\-AU)&$filter=(all_templates/any(t:t
eq 'cedd694630184d5ga5453e3214985678')) and latestversion_1}

Are we missing anything here? please suggest.

Sitecore version: Sitecore 8.2 update 4

Thanks in advance!

  • Can you post your content search code? Maybe using context.GetQueryable<YourSearchContentItemType>(new CultureExecutionContext(Sitecore.Context.Language.CultureInfo)) would help? – Marek Musielak Feb 22 '18 at 13:44
3

This is a known bug for Sitecore 9. I assume it will also be present in your version.

Check here: https://kb.sitecore.net/articles/125044 The bug number in v9 is 171546.

When Azure Search performs a search query that contains a hyphen for items that are filtered by language, it returns the item for all languages. (171546)

Contact Sitecore Support and you should be able to get a patch for it.

  • Thanks @Gatogordo - i requested patch for this from support which resolved my issue. – Ankit Joshi Feb 26 '18 at 5:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.