none
How to configure search results in Content search webpart RRS feed

  • Question

  • How to implement the below fields with AND condition in Query Text in Build your query tool in Content search webpart.

    Search results should retrieve based on the below condition:

    TypeOWSBOOL:0
    ColorOWSCHCS:Red

    Can someone explain how to implement this.


    Ganesh

    Thursday, November 14, 2019 3:23 PM

All replies

  • Hi,

    Based on your description, “TypeOWSBOOL” and “ColorOWSCHCS” are two managed properties generated from two custom columns, one Yes/No column named “Type” and the other Choice column named “Color”.

    Please do as following:

    1. Navigate to the Content Search web part on your page and click Edit web part > Change query. Make sure you have run a full crawl before you build the query.

    2. Click “Switch to Advanced Mode” and clear the Query text box.

    3. Select “Local SharePoint Results (System)” under "Select a query". Select "Only return items" under “Keyword filter” and then click "Add keyword filter".

    4. Under "Property filter", set “TypeOWSBOOL Equals Manual value 0”. Click "Add property filter". Repeat this step for “ColorOWSCHCS”.

    Save the changes and the Content Search web part should display all related results.

    Here’s a reference for you.

    Using site columns to create searchable metadata in SharePoint Online (Office 365).

    https://blogs.technet.microsoft.com/o365totd/2015/12/11/using-site-columns-to-create-searchable-metadata-in-sharepoint-online-office-365/

    Best regards,

    Chelsea Wu


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

    SharePoint Server 2019 has been released, you can click here to download it.
    Click here to learn new features. Visit the dedicated forum to share, explore and talk to experts about SharePoint Server 2019.

    Friday, November 15, 2019 8:50 AM
  • Thanks Chelsea, I added those two site columns in SitePages library. but those are not showing in Property filter. 

    How to make this columns display in Query text window. 


    Ganesh

    Friday, November 15, 2019 12:13 PM
  • Hi,

    Make sure you have created these two columns via Site Settings > Site columns and then add them to the Site Page library via Library Settings > Add from existing site columns.

    Also make sure the managed properties are set as Queryable and Retrievable via Central Administration > Search Service Application > Search Schema > Managed Properties, and properly mapped to at least one crawled property each.

    After all modification, remember to do a full crawl via Central Administration > Search Service Application > Content Sources.

    Best regards,

    Chelsea Wu


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

    SharePoint Server 2019 has been released, you can click here to download it.
    Click here to learn new features. Visit the dedicated forum to share, explore and talk to experts about SharePoint Server 2019.

    Monday, November 18, 2019 9:44 AM
  • Hi,

    I'm checking how it is going on with this issue.

    Please remember to update this thread if you have any progress.

    Thank you for your understanding.

    Best regards,

    Chelsea Wu


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

    SharePoint Server 2019 has been released, you can click here to download it.
    Click here to learn new features. Visit the dedicated forum to share, explore and talk to experts about SharePoint Server 2019.

    Thursday, November 21, 2019 9:07 AM