Optimistic Concurrency Control from Dynamics CRM 2015 Update 1

By | April 20, 2016

What is the need of Concurrency Control?

Systems such as Dynamics CRM are used by multiple users. When two or more CRM users need to update a same record at the same instance, then the changes made by the last user will be saved. There is no such concurrency control mechanism to stop users from overriding the changes made by others. This finally results into inconsistent data when the same fields are updated by the users.

Let’s take a look how the sanctity and the consistency of the data is maintained with the help of the concurrency control mechanism.

In general, there are two Concurrency Control Mechanisms:

A] Pessimistic concurrency control

When a user is modifying the data, another individual can’t access the same data at same time because the access has been locked.

B] Optimistic concurrency control

The record can be accessed but if you try to edit the record and the record is already modified since u last accessed it the modifications are not updated.

Since the release of CRM 2015 update 1, Optimistic Concurrency control method is been introduced while updating and deleting the record through UpdateRequest & DeleteRequest respectively.

Consider the account entity record, “A. Datum Corporation (sample)” with the details as shown in the screenshot below.Optimistic Concurrency Control from Dynamics CRM

We are retrieving this record from the code for updating it through UpdateRequest as you can see in the code block below:


Therefore, it is easier and simple to prevent the users from overriding the changes made by other users’ at the same time.

Hold… Are you planning to buy Bing Maps license for your Dynamics CRM? No need – Try Maplytics!

Leave a Reply