none
SharePoint online content search results web part to list all document libraries

    Question

  • In my publishing site I have creates a page in the pages library with a contest search web part. I edited the query and entered the following query text

    path:"http://siteurl" (contentclass:STS_List_DocumentLibrary)

    but this only returns one of the libraries in the search results.  This works fine in another site collection.  I checked that they both have the same site features enabled.

    Any ideas why only one library is being displayed?

    Thanks

    Friday, November 9, 2018 3:33 PM

Answers

  • Please set the query text for the content search web part to be like this: SPSiteURL:http://yoursitecollectionURL contentclass:STS_List_DocumentLibrary 

    Please remember to click Mark as Answer on the answer if it helps you

    • Marked as answer by Chris J Tuesday, November 13, 2018 2:18 PM
    Friday, November 9, 2018 9:55 PM

All replies

  • Please set the query text for the content search web part to be like this: SPSiteURL:http://yoursitecollectionURL contentclass:STS_List_DocumentLibrary 

    Please remember to click Mark as Answer on the answer if it helps you

    • Marked as answer by Chris J Tuesday, November 13, 2018 2:18 PM
    Friday, November 9, 2018 9:55 PM
  • Please check if you document library search setting is turned on or off. Go to advance settings of document library and see search options.

    2. Check if you have enough permission on the document library which are not visible to you.


    Please remember to click Mark as Answer on the answer if it helps you

    Friday, November 9, 2018 10:00 PM
  • Hi Chris,

    Is there any update?

    Search has security trimming feature, please check if you have permission to access the libraries as Lakshmanan said.

    Best regards,

    Grace Wang


    Please remember to mark the replies as answers if they helped. If you have feedback for TechNet Subscriber Support, contact tnmff@microsoft.com.


    Click here to learn more. Visit the dedicated forum to share, explore and talk to experts about Microsoft Teams.

    Monday, November 12, 2018 8:24 AM