# Calculated Fields in Microsoft Dynamics CRM 2015

With the recent release of Dynamics CRM 2015, Microsoft has introduced calculated fields in Dynamics CRM. Calculated fields allow you to define the value of a field using calculations operators or functions. You no longer need a developer on hand to write code, you can now create calculated fields using the CRM user interface. For example, a salesperson might want to automatically apply a discount based on an order greater than “X” dollars. The calculated field would be able to change the value using basic math operations or conditional operations.

Here is an example of a calculated field:

Order Total = ((quantity*unitprice) – ((quantity*unitprice) *Discount%/100)) + ((quantity*unitprice) – ((quantity*unitprice) *Discount%/100) *Tax%/100)

Here are some fields that are considered calculated fields:

•           Weighted Revenue: Estimated revenue multiplied by probability
•           Net Worth: Assets subtracted from the liabilities for a given account
•          Follow Up By: Follow up on an activity by a specified number of days based on priority The type of mathematic operations that you could use are:

•          = (Equal)
•          + (Plus)
•          (Minus)
•           / (Divide)
•          * (Multiply)

String Functions are :

CONCAT – Add singular lines of text together. It can be fields or actual lines of Text. If it is an actual line of text, then the text will need to be encased with double quotes.

TRIMLEFT – takes a single line of text and trims the number of characters starting from the left and working its way to the right.

TRIMRIGHT - takes a single line of text and trims the number of characters starting on the right and working its way to the left.

DateTime Functions are

Natalie Williams, Marketing Manager, WebSan Solutions Inc. a 2014 Ontario Business Achievement Award Winner for Sevice Excellence

### 3 thoughts on “Calculated Fields in Microsoft Dynamics CRM 2015”

1. Hi,
I have created a currency type calculated field in an A entity. I have B entity wherein I have a currency field. I have 1:N relationship B-->A, making B the parent entity. I am accessing the currency field in the calculated field to perform some calculation. The logic calculation in the calculated field seems to be valid as there is no error. However, there is no display on the screen.
When I try to hardcode the value of currency field,the calculated field value is displayed on the screen. Why is this so? It seems there is an internal error when a parental field is accessed in the calculated field.

1. Hi Jorge,