Index fields

Indexing Sitecore fields paves the way to a richer search experience. Here are some advantages you can draw from the indexing of fields:

  • In a search page, you can add a facet on an indexed field to empower your website visitors to zero in on the results that matter to them.

  • You can add field name and values to search result templates, therefore providing your website visitors with valuable data directly in search page results.

  • You can enable query syntax in your search boxes, allowing your website visitors to query on field values using comparison operators (see Comparison operators).

About the field indexing process

The Coveo for Sitecore indexing process takes your Sitecore fields and stores them as Coveo fields in your Coveo index. Depending on the way you want to have Coveo for Sitecore name your Sitecore fields in different indexes and the special characters you use in your Sitecore field names, some modifications to your field names can occur. The About Sitecore, Coveo for Sitecore, and Coveo Fields article is a must-read for any questions about the Coveo for Sitecore field indexing process.

Understanding how Coveo for Sitecore computes certain fields

Coveo for Sitecore computes certain fields it uses in search results, the two most important being the Sitecore item title and its clickable URI.

Since there are many ways to determine the search result title for a Sitecore item, Coveo for Sitecore prioritizes the different pieces of data it can use to set the title. Being aware of this order of priority allows you not only to understand the origin of the item title in the search results but also to make the necessary adjustments so your Sitecore item titles come out right in your search interface results (see About the title selection sequence).

As for the clickable URI, Coveo for Sitecore resolves the host name part of the URI at indexing time, but it can automatically override this host name at query time. This host name update is necessary in scaled environments where the clickable URI rendered in search results must be the reference to the item on a content delivery (CD) server. Reading up on how Coveo resolves the item URI at indexing and at query time can save you from unnecessary work (see How the site for the clickable URI is resolved).

Selecting fields to index

You want to index only the Sitecore fields you need to use in your search interface controls and search results. Coveo lets you specify the fields you want to index several ways. The recommended method is to use the Coveo Command Center user interface. Other options include editing configuration files directly and using the field indexing service API (see Specify which fields to index).

Field settings

Through field settings, you can enable field value-based search interface features such as facets, free text search, and result sorting.

Feature-specific articles in the Changing the Settings of Sitecore Fields section provide instructions on performing cross-index field configurations (see Change the settings of Sitecore fields). You can also override a cross-index field setting at the index level (see Manage fields for a specific index).

Reverting back to default field settings isn’t obvious as it involves editing your Coveo for Sitecore field setting configurations and doing the same in the Coveo Administration Console (see Reset a field setting).

Computed fields

Coveo for Sitecore lets you create computed fields programmatically. The Creating Computed Fields section gives you all the information you need to implement computed fields, including code samples (see Create computed fields).