Jean Paul's Blog

There are 2 types of People in the World, One who Likes SharePoint and..

  • Microsoft MVP

  • MindCracker MVP

  • CodeProject MVP

  • eBook on SharePoint 2010

  • eBook on Design Patterns

  • eBook on Windows Azure

  • NLayers Framework @ CodePlex

  • MSDN Forums

  • .Net vs. Java

    Due to Public Demand
  • Advertisements

Posts Tagged ‘dictionary’


Posted by Paul on May 16, 2014

In this article we can explore Thesaurus & its configuration in SharePoint 2013 Search.

What is Thesaurus?

Thesaurus is Synonym which means equivalent words.


Why do we need Thesaurus?

Users might find difficulty in typing lengthy search texts like:

1. Human Resource

Instead, they can use pre-configured Thesaurus like:

1. HR

2. HRA

How we specify Thesaurus to SharePoint 2013 Search?

First we need to create a comma-separated Thesaurus CSV file like below.


HR,Human Resources,en

HRA,Human Resources

The language parameter is optional.

How to configure Thesaurus?

We need to use PowerShell scripts to configure Thesaurus.


Let us try to configure Thesauri’s as an exercise.

Step 1: Initial Empty Search

Try searching for HRA and ensure you are receiving no results.


This confirms there are no content matching the text HRA.

Step 2: Create Thesaurus file

Create a CSV file with the following content.


HR,Human Resources

HRA,Human Resources

Save the file.

Step 3: Install the Thesaurus file

Run the following PowerShell script to install the Thesaurus file.

# Add PowerShell Snapin

if ((Get-PSSnapin “Microsoft.SharePoint.PowerShell” -ErrorAction SilentlyContinue) -eq $null)


Add-PSSnapin “Microsoft.SharePoint.PowerShell”


$searchApp = Get-SPEnterpriseSearchServiceApplication

Import-SPEnterpriseSearchThesaurus -SearchApplication $searchApp -Filename “\serverc$tempfile.CSV”

The path should be in UNC format. Please change the Server & File names appropriately.

If the installation succeeded, you will get the following message.


Step 4: Test the Search

Back in SharePoint; repeat the search using text HRA. You should receive the following results.


This confirms successful configuration of Thesaurus. Please note that the results are immediate.


Please note that I have configured content sources to This makes the content text Human Resources available.



In this article we have explored Thesaurus configuration.


Posted in SharePoint, SharePoint 2013 | Tagged: , , , , , | Leave a Comment »