Search Scope Rules - Property Values for “contentclass” Property

In my previous post on PowerShell Script to Create Search Scopes, I used “contentclass” property to create rules by selecting Property Query for scope rule type.

$rule = New-SPEnterpriseSearchQueryScopeRule -RuleType PropertyQuery -ManagedProperty "contentclass" -PropertyValue "STS_List" -FilterBehavior "Exclude" -url $webAppUrl -scope $createdScope -SearchApplication $SSA

Here is a list of various values for contentclass that can be used as property values:

Site:                                 STS_Web
Site Collection:                   STS_Site
Pages Library:                    STS_List_850
Page:                                STS_ListItem_850
Document Library:               STS_List_DocumentLibrary
Document Library Items:      STS_ListItem_DocumentLibrary
Custom List:                      STS_List
Custom List Item:               STS_ListItem
Links List:                          STS_List_Links
Links List Item:                   STS_ListItem_Links
Tasks List:                         STS_List_Tasks
Tasks List Item:                  STS_ListItem_Tasks
Events List:                       STS_List_Events
Events List Item:                STS_ListItem_Events
Announcements List:           STS_List_Announcements
Announcements List Item:    STS_ListItem_Announcements
Contacts List:                     STS_List_Contacts
Contacts List Item:              STS_ListItem_Contacts
Discussion List:                   STS_List_DiscussionBoard
Discussion List Item:            STS_ListItem_DiscussionBoard
Issue Tracking List:             STS_List_IssueTracking
Issue Tracking List Item:      STS_ListItem_IssueTracking
Project Tasks List:              STS_List_GanttTasks
Project Tasks List Item:       STS_ListItem_GanttTasks
Survey List:                       STS_List_Survey
Survey List Item:                STS_ListItem_Survey
Picture Library:                   STS_List_PictureLibrary
Picture Library Item:            STS_ListItem_PictureLibrary
Web Page Library:               STS_List_WebPageLibrary
Web Page Library Item:        STS_ListItem_WebPageLibrary
Form Library:                      STS_List_XMLForm
Form Library Item:               STS_ListItem_XMLForm
Search Query:                    urn:content-class:SPSSearchQuery
News Listing:                     urn:content-class:SPSListing:News
People:                             urn:content-class:SPSPeople
Category:                          urn:content-classes:SPSCategory
Listing:                             urn:content-classes:SPSListing
Person Listing:                   urn:content-classes:SPSPersonListing
Text Listing:                      urn:content-classes:SPSTextListing
Site Listing:                       urn:content-classes:SPSSiteListing
Site Registry Listing:           urn:content-classes:SPSSiteRegistry


Prasad Sampath Wickramasinghe said...

Another way to hide list views and other background pages from the search results is to use crawl rules. Go to Central Administration -> Search Service Application -> Crawl Rules. Exclude following paths one by one.


Staygreen Academy said...

Information was good,i like your post.
Looking forward for more on this topic
SharePoint Administration Training in Hyderabad

Rakesh Parval said...

Wooh this is very informative article. Thank you so much..!
SharePoint Developer Training in Hyderabad

Kiran Joshya said...

It is incredible and informative knowledge. Impressive.
SharePoint Training Institutes in Hyderabad

Manideep Agarwal said...

This article is very good.informative style.. brilliant piece of advice.
SharePoint Online Training in Hyderabad