Wednesday, December 24, 2014

How to Create Federated Search Results in SharePoint 2013

What is Federated Search in SharePoint 2013:
As its name suggests, Federated search combines search results from multiple search engines. Federated search allows you to consume search indexes created by search engines outside of SharePoint.

How Federated Search works in SharePoint 2013?
Federated Search basically uses the index created by an another search engine. When a search query  triggered from SharePoint, it is forwarded to an external search engine and SharePoint gets the result from that index, displays the results from all configured federated sources in a single page to allow users to view results from different sources. E.g. you can set up federated search to return content indexed by an external search engine like Bing, twitter, etc.  

When to use Federated search?
Federation comes to play when you can not crawl the data source. Federated Search only works with indexes compatible with OpenSearch 1.0/1.1. So, its compatible with other SharePoint farms - You can federate search across farms, YouTube, Bing, Twitter, Flickr, Technet, Wikipedia, etc. (Federated search is not compatible with Google yet - There are some workarounds however!)

How to Create Federated Search in SharePoint 2013 :

There are two steps involved in creating federated search in SharePoint 2013.
  1. Create a Result source for federated content source
  2. Create a query rule to include federated search results in SharePoint search results page
Step 1: Create a Result source for federated content source
Search Scopes are replaced with "Result Sources" in SharePoint 2013. It just defines where to look for results. E.g. Search for only documents, people, etc. at specific source such as farm, site collection or site level.

How to Setup Federated Search in SharePoint 2013:
Federated search can be configured either at site level or centrally from SharePoint central administration site. Its a good idea to configure federated search in SharePoint 2013 at Central Admin, so that it can be utilized globally.
  • Go to Central Administration >>  Application Management >> Manage service applications >> Select your  Search Service Application.
  • You'll be presented with the Search Administration page.
But wait! Here, I'm creating a result source at site level from search center site. Below steps are similar whether you are configuring federated search from Central admin or from a local SharePoint site. Lets configure SharePoint 2013 federated search with Bing at site level.
  • To start with federated search in SharePoint 2013, Navigate to Site settings >> Click on  "Result Sources" link under Search group.
  • From the Manage result sources page, click "New Result Source" link. SharePoint 2013 Federated Search Configuration
  • Enter the name for your result source:
    •  I've entered "Bing Search Results" 
    • Choose the Protocol as "OpenSearch 1.0/1.1
    • Source URL - This is important. Source URL specifies our source for Federation.
      • For Bing - Enter: http://www.bing.com/search?q={?searchterms}&format=rss&Market=en-US
      • For Twitter - http://search.twitter.com/search.atom?q={searchTerms}
    • Specify the credentials. I've specified "Anonymous". Click on "Save" button to create result source.
      sharepoint 2013 federated search results

Step 2: Create a query rule to include federated search results in SharePoint search results page
Query rules defines the outcome (Such as Promoted Result, Result block, etc) of search query.
  • From site settings page, Click on "Query Rules" link this time.
  • Choose Result source as "Local SharePoint Results" and click on "New Query Rule" link.
    configure federated search in sharepoint 2013
  • In "Add Query Rule" page, Give a name to your query rule. Click on "Remove Condition" link under Query conditions. In "Actions" section, click on "Add Result Block" link, You'll be prompted with the "Add Result Block" dialog box.
    sharepoint 2013 create federated search
  • In Add Result block page:
    • Enter the title for your result block. I've entered "Bing Search Results for "{subjectTerms}" 
    • In Query section, Choose the search source as "Bing Search Results" we created in step 1.
    • Choose Number of items to show in search results.
    • Under Settings, Choose "This block is always shown above core results"option. Click "Ok" to create a result block.
  • Click Save to save your query rule.
sharepoint 2013 federated search bing

That's all. We've done with SharePoint 2013 federated search configuration. Lets see the Federated search results in action:
sharepoint 2013 federated search results



You might also like:
SharePoint Usage Reports
Usage reports, collaboration and audit for SharePoint.
Document SharePoint Farm
Automatically generate SharePoint documentation.
*Sponsored


Check out these SharePoint products:

No comments :

Post a Comment

Please Login and comment to get your questions answered!

You might also like:

Related Posts Plugin for WordPress, Blogger...