Gravatar for

Question by nagasekhar, Dec 16, 2014 5:07 AM

Coveo Query for Sitecore

Hi ,

I am querying some items in Coveo.But im getting result as order by updated(order by item latest updated).But i need no change order when i am querying.How can i do in Coveo query. ex:-below query returning always latest updated items first.But i need as it is even i updated any item.please help me abc= LinqHelper.CreateQuery(searchContext, DataSourceSearchStringModels) .Where(result => result.TemplateId == templateId && result.Language.ExactMatch(contextLanguage)) .OrderBy(result => result["__sortorder"])

                    .Select(result => result.GetItem()).Take(1000)
1 Reply
Gravatar for

Answer by Vincent Séguin, Dec 16, 2014 7:36 AM


I'm not sure to entirely understand your question… On which field do you want to sort? In any case, when you want to sort on a field, make sure the field is declared as 'isSortable' in the fieldMap of Coveo.SearchProvider.config.

You can learn more about it on this page :'s+Configuration+File -> fieldMap section.

Ask a question