I am using a Content Search WebPart to search for a keyword from 100s of site collections under a web application. I have two content sources:

1. http://web.application (All the sites) 
2. sps3://web.application (People results). 

As the people results are crawled through 2nd content source also I am getting the people results when my search keyword matches the people names/logins.

As I know that the people results are pointing to mysite path. In order to exclude the people results i tried excluding them by Path. Below are the different query text used to exclude the results.

{SearchQuery} -Path:"sps3://"
{SearchQuery} -Path:"sps3://*"
{SearchQuery} -Path:"http://mysites"
{SearchQuery} -Path:"http://mysites*"

None of them exclude the people results.

But interestingly the query works and returns only people results if NOT is removed from the query.

{SearchQuery} Path:"sps3://"

Note: The default result source "Local SharePoint Results" is used in the Content Search WebPart.

May i know if there is a better approach to exclude the people results. I am okay even if the results are restricted using path.

1 Answer 1


Have you tried putting curly braces around it

{{SearchQuery} -Path:"sps3://*"}

Or try using the contentclass instead.

{{searchTerms} -ContentClass=urn:content-class:SPSPeople}

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.