0

I am using Sitecore 10.1 with Sxa on solr 8.4.1. The sxa scopes based on templates having any semantic tag is showing result in build query, but not on page preview nor published page.

Example query :

+template:{3f068cb6-080a-46d6-8212-848bd81e4e14};+tag:{B8D314E1-72AB-4F1B-A04A-3CAED1D89212};+location:{05CF23EF-08C3-466F-9A68-31E87B53DA72}

whereas query without tag is returning result. The above search query is working on Azure search service, thus wondering is there any limitation or configuration missed for solr search.

Although the steps to configure solr in sitecore instance is being done as mentioned Here and the JVM is Oracle Corporation Java HotSpot(TM) 64-Bit Server VM 1.8.0_241 25.241-b0.

Thanks in advance!

2 Answers 2

1

It looks like you are using two different indexes and expect the same results.

Compare translated search queries and pay attention to _indexname field.

This is unfortunate but queries in Build Search Query dialog are executed against Sitecore index, while these in Preview/Publish (in SXA context) will use SXA indexes.

There is no good solution/hotfix for that (to be able to observe SXA indexes results inside this dialog).

In your case, you have to inspect your SXA indexes and check index schema to validate if it has the same field (tag) included.

1
  • yes Alan , the field entry of Tag was missing in Solr Default index configuration file, which was already there in Azure DefaultIndexConfiguration file. Hence solved the problem, after adding the field.
    – Tabbuu
    Oct 25, 2021 at 10:05
0

From what I can tell, all the guids are lowercases in Solr.

I don't know how you built your query, but I saw it in the past that query didn't work if guids where not lowercases in Solr query.

Try using

+template:{3f068cb6-080a-46d6-8212-848bd81e4e14};+tag:{b8d314e1-72ab-4f1b-a04a-3caed1d89212};+location:{05cf23ef-08c3-466f-9a68-31e87b53da72}

If you still have issues, check in search logs what is the query which is sent to Solr. Then open Solr instance and execute the query directly in Solr without some parts of it to check which part of the query is causing issues.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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