Views:

Scenario Overview

In this business scenario we needed to support a business rule where any newly created products are automatically added to all price lists in the CRM system.
 
This formula will automatically find any active Price Lists in CRM and added your new Product to them.

N52 Formula Manager Solution

The Formula Manager solution works like this:

  • A formula of type 'Save - Perform Action' set up on the Product entity
  • When the new Product is created the formula will retrieve all active Price Lists and add an appropriate Price List Item to them

N52 Formula Manager Steps

The following set of steps outline how to create this Formula:

  • Create a new formula of type 'Save - Perform Action'
  • Set the Source Entity to 'Product'
  • Set the Mode to 'Server Side' and the Event to 'Create'
  • Copy and paste the formula below into the formula 
  • Click save and test

Formula

ForEachRecord(

          FindRecords('pricelevel', 
                  'statecode', '0', 
                  'pricelevelid'), 

        CreateRecord('productpricelevel',  
             SetAttributeLookup('uomid', 'uom' ,[product.defaultuomid]),
             SetAttributeLookup('pricelevelid',
                         'pricelevel', 
                         CurrentRecord('pricelevelid')
                      ),
             SetAttributeLookup('productid', 'product' ,[product.productid])
          )
 )

Wizard - FindRecords

Please see below the wizard you can use to create the FindRecords() function call used in this formula. 

Note for the Equals Value , you will need to search in the Source tab. 
 

Did you know?

Over 300 customers use North52!

Join over 300 organizations worldwide who trust North52 to drive their digital transformation into the future:

Serious Power without Code:  Easily build business rules, tests and data packages using our point-and-click editors. Even the most complex business rules are easily configured.

Build Fast:  We’ve built the North52 tools with our user’s productivity in mind – up to 10x faster than writing custom code.

Awesome Support:  We take pride in providing world class support to our customers and partners, ensuring you are successful with North52.

Future Proof:  We ensure your business rules and tests that you configure today, will continue to work with the ever changing Dynamics 365 platform.

Learn more about the North52 Decision Suite