I am using Sitecore 8.2 with Coveo 4.0.

I'm working on a multisite solution with two sites and created two crawlers inside a single index.

How can I make sure that on the search page data comes from the correct crawler of every site?

2 Answers 2


You can filter the results based on Site name. The below example

    function(e, args) {
        args.queryBuilder.constantExpression.add("<%= ToCoveoFieldName("site") %> = '<%=Sitecore.Context.Site.Name%>'");
    .coveoForSitecore('init', CoveoForSitecore.componentsOptions);

you can visit the below Coveo forums on this query.


  • Thanks a lot for your response. It a valuable thing for me. Aug 14, 2019 at 14:19

The alternative is to use Coveo filter expression rules if you have a pro license of Coveo. Coveo provides filter expression based on rule engine, where you can define the rule of child item of your website root or can compare the specific field value such as site field. you need to add expression rule on your Coveo search interface item - enter image description here enter image description here

  • Thanks a lot brother, as always you rock. Aug 14, 2019 at 14:28

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.