Get only current site documents SharePoint 2013

Hi Team,

Here is my scenario. Please help in achieving the same.

I have three sites--Root->Sub Site->Sub Sub Site

I need to get documents only from Sub Site in search results. To achieve this I have created a search results page in sub site and in search results I have given condition as below:

I have tried by restricting the sub sub site results using property filter on managed properties Path, Site Path and List URL as not contains manual value(which is sub sub site url as /subsubsite/). But still my results are coming with sub sub site in the path. Help me in framing this condition.

Thanks

R

February 4th, 2014 11:22am

you can use WebId:"you subsite ID here" instead  or restricte the query to not return the subsite using 

 NOT PATH:http://your_site/subsite/sub_sub_site"

Free Windows Admin Tool Kit Click here and download it now
February 4th, 2014 4:27pm

Hi Amr,

Thanks for the response. But I cannot hard code sub site as I have 20 sub sites and my query should be not as hard coded one to work whenever a new sub site is provisioned. Also sub sub site name is same in all sub sites.

Thanks.

February 5th, 2014 5:53am

So Don't use the PATH managed property use WebID instead

Free Windows Admin Tool Kit Click here and download it now
February 5th, 2014 6:10am

Does ID will be same for all sub sub sites of all sub sites.
February 5th, 2014 6:12am

It will be unique for the sub  Site 

you will use it like this 

WebID:{Guid_of_your_subsite} it will get only docs resides in that site

Free Windows Admin Tool Kit Click here and download it now
February 5th, 2014 6:19am

So I should hard code GUID in the property. But I cannot do that.
February 5th, 2014 6:27am

instead of using path managed property use the WebId:sub_site_id you already hardcoded the subsite path in your screenshot 
Free Windows Admin Tool Kit Click here and download it now
February 5th, 2014 6:54am

Try creating a new results source.

I think you can configure what results to be shown for a results source. Use this new result source in your

February 5th, 2014 7:46am

Sorry I din't hard code that. It came from condition the documents from current site in quick mode screen of query builder.

Thanks.

Free Windows Admin Tool Kit Click here and download it now
February 5th, 2014 11:43am

Hi Ram Prasad,

Even if I go for a result source I need to build same query. How that can be different from what am building above ?

Thanks.

February 6th, 2014 5:36am

Hi Team,

Please help with your inputs.

Thanks.

Free Windows Admin Tool Kit Click here and download it now
February 6th, 2014 5:23pm

So Don't use the PATH managed property use WebID instead

April 13th, 2015 11:41am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics