I am creating result types using PowerShell. While creating result type how can I match the content of result type?

enter image description here

1 Answer 1


By using this script you can compare the rules and other things.

$ssa = Get-SPEnterpriseSearchServiceApplication

$tenantOwner = Get-SPEnterpriseSearchOwner -Level SPWeb -SPWeb "http://URL/search/"    

$ResultType = Get-SPEnterpriseSearchResultItemType -SearchApplication $ssa -Owner $tenantOwner | where-object { $_.Name -eq "Microsoft Word" }

$ResultType2 = Get-SPEnterpriseSearchResultItemType -SearchApplication $ssa -Owner $tenantOwner | where-object { $_.Name -eq "PDF" }

$ResultType.Rules.ToString() -eq $ResultType2.Rules.ToString()
  • I need to create the result type with match a content field(PDF or Word,..) using powershell
    – Kumaraguru
    Commented Jan 18, 2017 at 15:38

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.