Is it possible to define search queries like this in Sharepoint 2013 on premises:

For all sub-sites which have a list (of content type InfoList) where a particular column in this list has a particular value (Status = Active), search the document archives for documents (of content type Pdoc) with a special tag (where Type of Doc = AAA).

I do not find it obvious how to do this in the query builder. I can get all sites, I can get the lists and I can get the documents. But how can I combine them in a query so that I will get only relevant documents?

1 Answer 1


You cannot do this in a single query. You would have to write multiple queries...something like.

  1. ContentType=InfoList Status=Active retrieve the Path to the containing Site.
  2. ContentType=PDoc DocType=AAA Path=Path from #1

You can do this in JavaScript or and App or C# Code depending on your skill level.

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.