Our business requirement is that when a user Qualifys a Lead record and an Opportunity gets created, we need to move any notes that users entered on the Lead entity across on to the Opportunity.
In our example our users have access to Leads but not Opportunities.
They will not be able to make the changes required on an Opportunity so we will execute this formula as the Admin account to allow for the specific changes to occur.
North52 Decision Suite Solution
The North52 Decision Suite solution works like this,
- Whenever an Opportunity with an Originating Lead is created, the formula is triggered
- The formula will first retrieve all notes related to the Lead
- Then it will change the reference guid (i.e. Move) the Note from the Lead to the Opportunity
North52 Decision Suite Steps
The following set of steps assumes you are just using the out of the box Dynamics 365 setup. But its easy to enhance if you have extra fields/requirements.
- Create a new formula of type 'Save - Perform Action'
- Set the Event field to just 'Create'
- Set the Source Entity to 'Opportunity'
- Set the Source Entity Property to 'Originating Lead'
- Under Deployment Settings , set Execute As to 'System User (Administrator)'
- Copy and paste the formula below into the formula description field and click Save
- You are ready to test
if( ContainsData([opportunity.originatingleadid]), ForEachRecord( FindRecords('annotation','objectid',[opportunity.originatingleadid],'*','50','true'), UpdateRecord('annotation', CurrentRecord('annotationid'), SetAttributeLookup('objectid', 'opportunity', [opportunity.opportunityid])) ) , 'NoOp')
Wizard - FindRecords
Please see below the wizard you can use to create the FindRecords() function call used in this formula.
Note to find the value for Entity Name, you need to select "Note" and for the Where attribute, select Regarding.
Did you know?
You can easily schedule recurring processes or CRM record updates
Every business has recurring processes and tasks that need to be done on repeatable and scheduled basis. Microsoft Dynamics 365 users are often surprised to learn that it is difficult to achieve using standard functionality. The North52 Scheduler makes it easy to trigger workflows and/or advanced business logic for specific entity records on a scheduled basis.
Key features include:
- Create Recurring Schedules within Dynamics CRM
- Powerful Record Targeting - easily create queries to target a specific set of records
- High Performance - can process 100,000+ records on a scheduled basis
- Execute Workflow/Action or Update Entities
- Native to Dynamics 365