Skip to content

MobileCRM.FetchXml.Entity.orderBy

rescocrm edited this page May 15, 2023 · 8 revisions

Adds an order by statement to the fetch query.

Arguments

Argument Type Description
attribute String The attribute (CRM logical field name) to order by.
descending Boolean false, for ascending order; true, for descending order.

Following example creates the fetch entity for account with ascending order by "name" field.

var entity = new MobileCRM.FetchXml.Entity("account");
entity.addAttributes();
entity.orderBy("name", false);
Clone this wiki locally