Open the browser and get the SXA query -
The query will look like this -
this query will be generated based on the scope items and settings like sort order etc.
Now, check the solr logs -
Path - Your solr root directory/server/logs
Generate the SOLR query and try in Solr admin panel.
Example -
https://localhost:8983/solr/xp930_sxa_master_index/select?q=_template%3A(f6357da575384e9d8caaaa08fd345f5e)
Compare the data, in this example, I fund that the query was searhing for "searchable_b":true, but the actual data was "searchable_b":false,
The problem is that the
"searchable_b":false is false and the query is expecting it "searchable_b":true
Solution - by default all pages under home are searchable and for data items, basically we need to perform two things.
1. Add the _Searchable base template -
2. Go to settings and add the associated content.
Here is the result -
1. Before changes -
2. After changes -
Please let me know if you have any issue in SXA search-related components. I will happy to help :)
The query will look like this -
{ "endpoint":"//sxa/search/results/", "v":"{224530AA-968E-49AB-84B1-AFA3BB52A589}", "s":"{3758B0CF-81A6-4DD3-AF1F-9F27A13740D5}", "l":"", "p":2, "defaultSortOrder":"Title,Ascending", "sig":"dd", "itemid":"{9DF8EC39-57F4-48B4-A2A4-0F13BEF66C63}", "autoFireSearch":true }
this query will be generated based on the scope items and settings like sort order etc.
Now, check the solr logs -
Path - Your solr root directory/server/logs
Generate the SOLR query and try in Solr admin panel.
Example -
https://localhost:8983/solr/xp930_sxa_master_index/select?q=_template%3A(f6357da575384e9d8caaaa08fd345f5e)
Compare the data, in this example, I fund that the query was searhing for "searchable_b":true, but the actual data was "searchable_b":false,
The problem is that the
"searchable_b":false is false and the query is expecting it "searchable_b":true
Solution - by default all pages under home are searchable and for data items, basically we need to perform two things.
1. Add the _Searchable base template -
2. Go to settings and add the associated content.
Here is the result -
1. Before changes -
2. After changes -
Please let me know if you have any issue in SXA search-related components. I will happy to help :)
Hi jitendrasoni,
ReplyDeleteI have done the above changes but still am not able to get the results. Please help me to solve the issue
Hi Yugandhar,
DeleteDid you see your items in Solr? If yes try to refresh Sitecore cache - admin/cache.aspx
or if you haven't see data in Solr, Please follow step 1 and 2 and do the reindeing.
Thank you jitendrasoni, It helped me a lot
ReplyDelete