Forum Discussion

Rachel Lim's avatar
Rachel Lim
Copper Contributor
Jun 23, 2017

Add new search refiners to multiple existing sites

Hi All,
I am using Office 365 / SharePoint Online and I would like to add a new refiner mapped property and deploy them to multiple sites.

I tried to set the mapping through the Search Schema UI in one existing site (Site A) then I export the Search Configuration. From the exported xml file, I can see that the new refiner string mapping is there and I replace the SearchConfigurationSettings to my SearchSettings.xml file.

I need to update all my exisitng sites with this new property mapping in order to see these new refiners in those sites. I tried to push the SearchSettings.xml file (which i exported as mentioned above) but I keep getting some internal error. Normally for any new field in list or new content type, I just need to put the newly added part into the template.xml and deploy to existing site then the newly added part will be applied to that existing site. But this seem doesn't work for SearchSettings.

 

I got the following error:

[FaultException: The server was unable to process the request due to an internal error.  For more information about the error, either turn on IncludeExceptionDetailInFaults (either from ServiceBehaviorAttribute or from the <serviceDebug> configuration behavior) on the server in order to send the exception information back to the client, or turn on tracing as per the Microsoft .NET Framework 3.0 SDK documentation and inspect the server trace logs.]

Can someone please help to guide me how do I turn on the IncludeExceptionDetailInFaults so that I could see the actual error message.

Found some post which required Open IIS and navigate to “SharePoint Web Services” under “Sites”. Since I am working on sharepoint online and my service is hosted in azure site, I cant perform this.

 

I am new to sharepoint online pnp, can someone please help? Basically what I need is to deploy the new property mapping for search configuration to multiple existing sites (do it programmatically instead of using Search Schema UI) thanks!

  • Ho did you create the fields in the different sites. If you created them through the Office 365 UI then you will have different fields. Each field will have an internal name and an internal GUID. This Guid is uniquely generated when you create the field.

     

    You will have to use templates ( either PnP templates or 'Save as site template') or you can use code(c# or PowerShell) to create the fields.

     

     

Resources