How to Fix SharePoint Search Treating Minus Sign as Exclusion Operator
Question details
Users are unable to find specific files in SharePoint when the file name contains a minus sign (hyphen), as the search engine treats it as an exclusion operator.

- Product
- SharePoint
- Device & OS
- not provided
- Scenario
- Searching for documents that include dates or hyphens in their file names, such as '10-10-10 This is a Test'.
- Observed behavior
- The search query omits results containing the terms after the minus sign instead of finding the exact file name, leading to missing or unexpected search results.
Identify the exact file name or the specific phrase containing the minus sign that you are trying to locate in your SharePoint document library.
Use Quotation Marks for Exact Phrase Matching
Enclosing your search query in quotation marks forces SharePoint to treat the minus sign as a literal character rather than an exclusion operator.
By default, SharePoint search syntax uses the minus sign as a logical NOT operator to exclude terms. Wrapping the phrase in double quotes overrides this behavior by initiating an exact phrase search.
Navigate to your SharePoint site or the specific Document Library where the file is stored and click on the search box at the top of the page.
Type your entire search phrase wrapped in double quotes. For example, enter "10-10-10 This is a Test" instead of typing it normally.
Press the Enter key or click the magnifying glass icon to perform the search. The expected file should now appear in the results.

Utilize Wildcard Characters
Replacing the minus sign with a wildcard character can help you bypass the exclusion logic while still finding the relevant files.
Manage Your Documents Seamlessly with WPS Office
While SharePoint and Microsoft Office search quirks can occasionally slow down your workflow, switching to WPS Office provides a lightweight, highly compatible, and user-friendly experience for managing, editing, and searching your documents without complex operator restrictions.
- 1. Download the application: Visit the official WPS Office website and download the free installation package for your operating system.
- 2. Install WPS Office: Run the downloaded installer and follow the simple on-screen instructions to set up the suite on your device.
- 3. Organize your files: Open WPS Office and use the unified dashboard to easily search, organize, and manage your local and cloud documents.
- 4. Edit with perfect compatibility: Open your existing .docx, .xlsx, and .pptx files directly in WPS Office to experience seamless editing and formatting.

Frequently Asked Questions
Can I permanently disable the minus exclusion operator in SharePoint Search?
No, SharePoint does not provide a built-in administrative option or setting to disable the minus sign's function as an exclusion operator. You must rely on search workarounds like quotation marks.
Why does SharePoint treat the hyphen as a minus sign?
In standard Microsoft search syntax, the hyphen (-) and the minus sign are treated as the same character, which functions as a logical NOT operator to help users easily exclude specific words from their search results.
Do these search workarounds apply to both SharePoint Online and on-premises versions?
Yes, enclosing search terms in quotation marks or using wildcards to bypass the exclusion operator works consistently across SharePoint Online, Microsoft 365, and SharePoint Server on-premises environments.




