·
5 min read

Filter your data for mobile offline usage on Microsoft Dynamics 365

Microsoft Dynamics 365 users can work with mobile application in offline mode, even when the device is disconnected from the network. The application provides a rich offline experience which lets you to work with all basic commands like create, read, update, and delete and business processes – so your productivity is not impacted when you are not online.
Mobile Offline can be setup by Dynamics 365 administrator in an organization1. Administrators can select and choose the entities, and corresponding data that users can work with in offline mode based on business requirement. Filtering the right set of data for offline ensures effective utilization of your device memory and network bandwidth.
Dynamics 365 provides offline service by replicating Dynamics 365 data in Azure, and synchronizing the data from the Azure to mobile client devices. An administrator can filter the data for offline usage at these two stages.

  1. Organization Filter
  2. Profile Filter

Stages for filtering

 

 

ORGANIZATION FILTER

These filters determine the offline enabled entity’s data that gets replicated in the Azure Middleware. This data filter is applicable at organization level i.e, the data replicated in Azure for entire organization.

Administrators can define this filter from “Settings -> Customizations -> Customize the system”. Navigate to entities from “Components -> Entities” and select any entity. In the general tab of entity, you will have an option to enable it for mobile offline.

 

Enable entities for mobile offline

 

Once an entity is enabled for mobile offline, you can define organization data download filters on this entity.

 

Edit organization data filter criteria

 

These filters can be defined based on field attributes of entity. You can filter based on date-time, single line of text, option-set or whole number field attribute data types. This filtering is not supported on roll-up and calculated fields and this filtering is supported only on searchable fields. In the example in the screenshot here we have defined filter to download accounts modified in last 10 days.

Note: We have enabled some entities out of the box for you with pre-defined organization filters for you to start working offline with minimum customization. You can disable these entities for offline, or edit the organizations filters of these entities based on your business requirement.

PROFILE FILTER

Administrator defines the data that gets downloaded from Azure onto a user’s mobile client device using Mobile Offline profiles3. These profiles can be configured from “Settings -> Mobile Offline -> Mobile Offline Profile”.

 

Mobile offline profiles

 

Note: There are two out of the box profiles defined for you to start working in offline with minimum customization. You can use these profiles as it is, edit them, or create new based on your business requirement.

You can define data rules on any offline entity in a profile using profile item artefact. There are four filtering options to choose from in a profile item – Download related data only, All records, Other data filter and Custom data filter3.

 

Options in profile item record

 

You can filter data based on an entity’s field attribute, ownership or relationship, or a combination of these using the four options. Let us look at all these capabilities in detail in following sections.

  1. No Filtering
    In profile item definition for an entity, you can select ‘All records’ to download all the records of this entity from Azure to offline DB on client.

 

Data download filter - All records

 

For example, in the screenshot above – an user associated with this profile will have all the leads from Azure downloaded onto his client device for offline usage.

  1. Advanced Custom Filtering3
    In profile item definition for an entity, you can select ‘Custom data filter’ to filter the data based on any field attribute. You can filter based on date-time, single line of text, option-set or whole number field attribute data types. This filtering is supported only on searchable fields.
    After selecting ‘Custom data filter’ click on ‘Define filter rule’ to open a dialog box where you can define filter rules. You can define up to six rules. Each of these rules can also be combined using ‘AND’ and ‘OR’. Following is an example of the custom filter on Account profile item:

 

Data download filter - Custom filter

In this example, a user associated with this profile will have active accounts owned by her/him and modified in last seven days in the offline DB on client.

  1. Filtering only on ownership
    In profile item definition for an entity, you can select ‘Other data filter’ to filter the data based only on ownership. You can use this option in the organizations running on version older than CRM spring 2016. You have following set of filters to choose from based on the type of entity:
  1. User or Team owned entity
    1. Download my records
    2. Download my team’s records
    3. Download my business unit’s records
  2. Business owned entity
    1. Download my business unit’s records
  3. Organization owned entity
    Not Applicable

Following is an example of other data filter on opportunity profile item

 

Data filter on opportunity profile item

 

In this example, a user associated with this profile will have opportunities owned by her/him downloaded onto his client device for offline usage from Azure Middeware.

 

  1. Filtering on relationship
    You can also define rules to download data based on relationship. This can be achieved using profile item association artefact. For example, consider you want to download contacts only related to offline accounts. For this you add a profile item for contact entity and define filter to download only related data (This is in addition to profile item for account entity that defines rules for accounts in offline DB).

 

Data download filter - Related data only

 

And, on the profile item of account entity you define a profile item association to download the contacts related to accounts.

 

Define profile item association

 

  1. Advanced Customer Filtering on Relationship3
    You can also further filter data on related entities using advanced custom filters3. This can be achieved by defining custom filters on profile item association same as on profile item.

 

Filter contacts related to offline accounts

 

In our example above, we further filter contacts related to offline accounts, to have only those related contacts owned by user and from a specified location in user’s client offline DB.

These are the various organization and profile filter capabilities available to administrators to filter data for their users for offline usage.

 

– Karthik Gangidi