Questions tagged [content-search]

Questions about searching (querying) Sitecore projects with the ContentSearch API. Use the Lucene or Solr (or Coveo) tags if the question is specific for any of those technologies.

Filter by
Sorted by
Tagged with
3
votes
1answer
387 views

Add facets to the Content Editor search page

I have a folder which is a bucket and I'm using the search functionality to get the results. By default I have 4 facets on the right column: Template, Language, Author and Date Range. I see on the ...
2
votes
2answers
489 views

Search in content editor for checkbox field value

In the content editor's search functionality, is there a way to perform a search to find items where I'm checking for the value of a boolean/checkbox field? Like if I have an "active" checkbox in my ...
2
votes
1answer
423 views

Way to prioritize title field for search results?

Can we adjust the Lucene search results so that items most likely to be related are shown closer to the top of the results feed - I'm thinking this would involve providing higher weight to results ...
2
votes
1answer
142 views

Use the TermFreq() function programatically in Sitecore

I was building query on the basis of the occurence/relevancy of the terms present in a field and got one issue , suppose i searched for a keyword "text" in the content field , and i want to sort the ...
2
votes
2answers
715 views

Solr search query by Datetime.Year

I configured Solr index to the path where I created some articles using templates, templates have the same fields with data type as in below model <Root>/sitecore/content/Articles</Root> ...
2
votes
3answers
515 views

Error in custom index after upgrading to Sitecore 9

After upgrading to Sitecore 9 and converting custom index files from using Lucene to Solr, I am getting the following error on an Ajax call: Unable to cast object of type 'System.Collections....
2
votes
2answers
281 views

SXA get data based on current year

I work on sxa Project where I have news Template, I trying to display all news items where the (News_Creation_date)field value in current year, I created search Scope to retrieve data and Rendering ...
2
votes
1answer
1k views

Rebuilding Indexes with SOLR throws Exceptions

I set up a fresh Sitecore 9.1 with SXA on my local machine. When rebuilding the indexes, I get the following messages: (Core) 19676 14:50:03 WARN Could not compute value for ...
2
votes
1answer
707 views

Custom Azure Search Index returns '&search=This_Is_Equal_ConstNode_Return_Nothing' for searches

I have setup an custom Azure Search index in Sitecore 8.2 u7 and was getting no results returned even though I have data in it (I can see the data in the Azure console). Looking in the Sitecore Search ...
2
votes
1answer
490 views

Sort SXA search results by date without SXA sorting rendering

I have a list of blogs, and I'm using the Search Results component to render them. I need to order them by date: specifically, to show the most recent ones first, so they'd be ordered newest date ...
2
votes
2answers
100 views

How to avoid errors when item assigned to Lucene index is removed?

When a user changes the name or deletes an item with a Lucene index attached to it, Sitecore will throw errors when using any index based functionality - it can break site sometimes. I can think of 2 ...
2
votes
1answer
124 views

Search the content of a PDF file uploaded in media library

I'm using sitecore 9.3. I have a case where i have some content files (ex: PDF files) uploaded to sitecore media library and I have a search box component. I need to configure my search box scope to ...
2
votes
1answer
92 views

Issue with the Like operator on my custom field

My field configuration on Sitecore: <field fieldName="unifiedtitle" storageType="yes" indexType="tokenized" returnType="string">Project.Foundation.Indexing.ComputedFields....
2
votes
2answers
315 views

Get the Json result thrown by SXA Search before rendering it

Working with Sitecore 9 (Update 1), SXA 1.7 and Azure Search. I am using the Map component along with Location Finder and Search Results component. I want to do some changes on the results thrown by ...
2
votes
2answers
250 views

How to load search result based on user location by default

I want to load the search results by user’s current location by default or first time when user lands on the page. Does Sitecore supports this feature OOTB or or any custom solution available? I’m ...
2
votes
2answers
770 views

Computed index fields on Sitecore 9.1.1 CD server

I have a custom computedfield in Sitecore 9.1.1. I am getting the below error on CD server only as my web.config has: <add key="role:define" value="ContentDelivery" /> Current CustomIndex ...
2
votes
1answer
447 views

Index Update Strategy not Firing on Publish End with Custom Publishing Target and Custom Solr Index [duplicate]

We have a prod set up that has one CM and two CDs. The CD servers serve content from a second web database that we call "live". This database is a clone of web. We use web as a staging environment on ...
2
votes
1answer
124 views

Do we need to trigger SXA indexes after cloning a new site?

This is the first time working on SXA Search. We have an SXA site with search in working condition. We cloned a new site from the existing one and using master database for now but the search page is ...
2
votes
1answer
383 views

SXA Checlikst filter not working with special characters

SXA Checlikst filter is not working when filtering by a choice with a special character like : '&' then filter by other filter I think the problem is in the encoding because when I checked the ...
2
votes
1answer
1k views

Could not resolve type name error while performing search in Sitecore in Content tree

After logging to the Sitecore content tree, getting the below error while performing the search. An error occured while searching. Rephrase the query. Could not resolve type name: Sitecore....
2
votes
1answer
260 views

What is Sitecore.ContentSearch.SearchTypes.Content Property which maps solr _content field?

What is _content in SOLR. While mapping through Sitecore, what are the fields will it map? Is it good practice to use Content property in search query builder? In that case, How will it work in ...
2
votes
1answer
711 views

How do I search for a value in a parent item field?

I have several items (news stories) that are contained within a section (like a category) that span multiple issues and publications. The sections are mostly repeated in every issue and many times ...
2
votes
1answer
112 views

How Coveo reads indexes?

We are using Coveo on perm 4.0 edition with Sitecore 8.1 update 3. We have CM and CD configured to use the Coveo indexes. When I query the results on CM and on CD it uses different indexes So how ...
2
votes
1answer
460 views

How to search by a date with ContentSearch and IObjectIndexers

I have a generic search method which should be able to search based on any field. I have something like this: criteria = x => x[FieldName] == fieldValue; This works well for strings but, how can I ...
2
votes
1answer
73 views

How to make a cache exist for the duration of an indexing operation

Is there a way to create a Sitecore custom cache which exists for the duration of an indexing operation. I would like to store frequently looked up relationships which can be re-used by different ...
2
votes
1answer
56 views

Cannot search sxatags to find related items - 'undefined field sxatags'

Sitecore 9.3 with SXA. I'm trying to utilise sxa tags from the inherited _Taggable template to programmatically find related items with similar tags to the context item. That SXA template is /sitecore/...
2
votes
1answer
641 views

How to apply stop words at Solr query time?

I'm having some fun with Solr and here is my current issue. I've applied some stop words using the stopwords.txt file and rebuilt my indexes. Everything looks fine here, I can see that those stop ...
2
votes
1answer
60 views

SXA Autosuggestion work after two characters

I'm using Sitecore 9.1 and SXA 1.8, the autosuggest works after entering two characters if I want to change it and make it work like after three characters, Where can I change it.
2
votes
1answer
219 views

Excluding template fields from indexing - difference between documentOptions exclusion vs regular exclusion

I reducing the number of fields which get indexed in my site. I looked at App_Config\Include\Sitecore.ContentSearch.Azure.DefaultIndexConfiguration.config and see the section <configuration <...
2
votes
2answers
1k views

Results are not coming in the order using sortorder from lucene index

I have some items present in an item folder and want them to retrieve from Lucence index. There is a requirement that we have to order items in the Sitecore based on the order set on the Sitecore CMS, ...
2
votes
1answer
1k views

How to configure SXA Search Box to search based on Fields of a certain template?

I want to add a Search box in a blogging website, specifically on a page where all the blogs appear in a "search results" component. I've tried adding the SXA search box component and connecting it ...
2
votes
2answers
2k views

How to correctly login as Virtual User to use the Sitecore Content Editor? (Avoid Media Library Search redirects)

I have a situation where I need to use VirtualLogin to enable a user to access the sitecore shell and use the Content Editor / Media Library editor. This is the code for the Virtual Login (from many ...
2
votes
1answer
487 views

Search not working in multi-language site

We are using Azure search. This is a website search. End user enters the keyword and the pages where it is present in the content, are returned as search results. The functionality works fine when ...
2
votes
1answer
2k views

SolrNet.Exceptions.SolrConnectionException when trying to configure custom Solr index

I am migrating a project from 8.2 to 9, and moving indexes from Lucene to Solr. The default indexes are fine, but my custom index is throwing an exception: 53416 08:51:21 ERROR Unable to connect to [...
2
votes
1answer
471 views

Content Manager returns empty list

I am on v8.2 Using SOLR as search index. I have the items indexed and can see them in the index. I kicked off index rebuild a few times. However, ContentSearchManager.GetIndex("sitecore_web_index")....
2
votes
1answer
602 views

Sitecore Context Database during computeField index

When I call Sitecore.Context.Database inside of an IComputedIndexField, it returns Core. I can't use this to call the GetItem() function. Thus, I wrote the following as a workaround. var ...
2
votes
2answers
944 views

Perform multi-language search sitecore

I have small issue with search results where its showing duplicate items because it has different version created and sometimes it only shows default language version. The code i have is as per ...
2
votes
1answer
94 views

Clone SXA OOB component javascript

I am using Sitecore 9.1 and SXA 1.8, I need to clone "component-search-results-count.js" in base theme to extend some functionality to the OOB "Search Result Count" component. How can I do that?
2
votes
1answer
54 views

Filtering Content Editor global search in SOLR

When I use the global search in the Content Editor in my Sitecore 8.1 instance (that uses Lucene), the search.log displays the following output: ExecuteQueryAgainstLucene (sitecore_master_index): ...
2
votes
1answer
126 views

Rebuild all Solr indices script hangs

I have a piece of code that performs a full rebuild for all Solr cores (using Sitecore XP 9.1.1): foreach (Sitecore.ContentSearch.ISearchIndex index in Sitecore.ContentSearch.ContentSearchManager....
2
votes
1answer
242 views

Resolve PostFailedForSomeDocumentsException exception during indexing

During (manually triggered) indexing of the master database, I get the following exception (stack trace below). Using Sitecore 8.2u7 with SXA 1.7. 27608 10:43:03 ERROR [Index=sitecore_master_index] ...
2
votes
2answers
2k views

Searching a substring using solr

I am trying to move my code from Lucene to Solr, but am facing an issue. I have 4 fields indexed, all the field are of text_general type (from the managed schema). The code from Lucene is: ...
2
votes
3answers
785 views

Issue in SXA search scope: no results due to searchable_b:(True)

I am using SXA in Sitecore 9, I have created simple search scope with below query: template:{cbb0f1aa-1a19-4c0a-a897-49af144cb801};+location:{3F38A230-25BB-4DBA-B9D3-2CE94F842072} From UI there are ...
2
votes
1answer
578 views

Rule to set datasource based on search result

Using sitecore 8 (8.2 update 3 to be specific) I'm looking to be able to create a rule based on some condition which will set the datasource (and maybe rendering) to the most appropriate result from ...
2
votes
1answer
429 views

Query item in Xpath [closed]

i have 2 sites, A and B in Sitecore. Some items in site A are linked to items in site B. I need a query to list all items in site A that are linked to any items in site B. I can't touch in code. Any ...
2
votes
3answers
1k views

SearchResultItem POCO not populated

I have a class (SBJSearchItem) that inherits SearchResultItem that I'm using with the ContentSearchManager. The problem is that some of my SBJSearchItem properties are not populating. I'm using Azure ...
2
votes
2answers
78 views

Sitecore SXA search result count in scriban

Is there a way to read the search results count in a Scriban template in a rendering variant of SearchResult in SXA? I have a requirement that if the search results count is less than 6 the result ...
2
votes
1answer
79 views

Boosting Search Results

I was disheartened to see this in the Sitecore docs: Important Search result boosting works in Solr version 6.6 or earlier, but Solr changed the implementation in Solr 7, and later versions. ...
2
votes
2answers
76 views

Can I add a custom rendering for the out of the box search box and dropdown filter?

I want to create my own render variant for the search box and dropdown filters. I wantt to keep the functionality, but I want to change some of the markup and css classes. Is this possible, and how? I ...
2
votes
1answer
212 views

SXA Search Boosting Throws Error

I have configured the search scope for SXA (Sitecore 9.3) and it works as expected. However, when I try to add boost configuration to the search scope it throws the below error. Invalid Method Call ...

1 2 3
4
5
9