Feedback
 
Did this article resolve your question/issue?

   

Your feedback is appreciated.

Please tell us how we can make this article more useful. Please provide us a way to contact you, should we need clarification on the feedback provided or if you need further assistance.

Characters Remaining: 1025

 


Article

Search: No search results are found when searching with colon in the search query

« Go Back

Information

 
Article Number000098350
EnvironmentProduct: Sitefinity
Version: 5.x, 6.x, 7.x, 8.x, 9.x, 10.x, 11.x, 12.x
OS: All supported OS versions
Database: All supported Microsoft SQL Server versions
Question/Problem Description

When using a colon (":") in the search query, no search results are returned.

Steps to Reproduce
Clarifying Information
Lucene is used as a search service.
Error Message
Defect/Enhancement Number
Cause
When the search terms are parsed, Lucene considers the colon as part of the native query in Lucene and as a result, an incorrect query is constructed.
Resolution
For WebForms based widget:
1. Go to Administration > Settings > Advanced > Search > SearchInputValidation and create a new validation with the following parameters:
MatchPattern: add a colon in the input field
ReplacementString: add a space in the input field
Enabled: True

For MVC based widget:
1. Extend the search results model using the article in the notes and modify the search query by replacing the colon (":") with an empty space.
Workaround
Notes
Progress Article(s):
000079700, Search: Override MVC Search results widget
Attachment 
Last Modified Date9/11/2019 5:32 AM