Managing Top Result Items in Sitecore
Managing Top Result Items in Sitecore
On-Premises only
With Coveo Cloud, Top Results have been renamed Featured Results and are managed from the Query Pipelines. See Manage Featured Result Rules.
Since Top Results can be configured using standard Sitecore items, it’s quite easy to manage.
- Navigate to the
Top Results
folder. The default path is/sitecore/system/Modules/Coveo/Top Results
. - Right-click the folder and create a Top Results item.
- Give the new item a meaningful name. The Queries field is filled automatically with the name of the top result.
-
The Items field allows you to select which items need to appear first in the results list. The items appears in the same order as those defined in the field.
You have to enter a value in both the Queries and Items fields. Otherwise, your item won’t be synchronized.
-
In this example, there’s one top result with the query
design
which presents two items. The first one is a sports car, and the second one is a luxury car.You can modify and remove Top Results as you would do with any other Sitecore item. You can also clone and duplicate Top Results items.
-
When searching the site with the
design
query, you can see that the selected items appear in the right order.A Coveo-Powered Search Page allows the sorting of results according to many criteria (for example, by relevancy, by date,or by a specific field). Since Top Results are essentially a way to improve the ranking of specific search results, they’re only considered when results are sorted by Relevancy.
A Word About Item Versions
Sitecore items can be versioned in two different ways: numbers and languages. Here is how they’re both supported by Coveo for Sitecore.
The Top Result
template looks like this.
As you can see, the TopResultDocuments field (entitled Items) is configured as Public. It means that, for a top result, the field value will always be the same no matter if a numbered or language version is used. On the other hand, the TopResultQueries field (entitled Queries) is a regular field; its value can change according to number and language versions.
This allows for a better support of localized Top Results. It also allows you to add a language version without having to reconfigure which items should appear in the search page and in what order. The items list is always the same, and the synchronization mechanism takes care of matching the items language with the top result language. Number versions aren’t a concern either, as the synchronization mechanism automatically uses the latest version of the top result and referenced items.
Publishing Top Results
As you probably know, Coveo for Sitecore uses different indexes for each Sitecore database. Even if the top result configuration is global in CES, Top Results are still independent by database and language. It means that you need to publish the top results and they need to be synchronized before it can affect the user search on the public website.
What’s Next?
- You can now proceed to Synchronizing Top Results Automatically.