• Home
  • About Us
  • Contact Us
  • Privacy Policy
  • Special Offers
Business Intelligence Info
  • Business Intelligence
    • BI News and Info
    • Big Data
    • Mobile and Cloud
    • Self-Service BI
  • CRM
    • CRM News and Info
    • InfusionSoft
    • Microsoft Dynamics CRM
    • NetSuite
    • OnContact
    • Salesforce
    • Workbooks
  • Data Mining
    • Pentaho
    • Sisense
    • Tableau
    • TIBCO Spotfire
  • Data Warehousing
    • DWH News and Info
    • IBM DB2
    • Microsoft SQL Server
    • Oracle
    • Teradata
  • Predictive Analytics
    • FICO
    • KNIME
    • Mathematica
    • Matlab
    • Minitab
    • RapidMiner
    • Revolution
    • SAP
    • SAS/SPSS
  • Humor

Use Microsoft Flow with Dynamics 365 for Customer Engagement

October 2, 2018   Microsoft Dynamics CRM
flow customer engagement blog 300x225 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Take action on data across multiple cloud services with Microsoft Flow. No code required! Use a visual editor to design a logical flow which automates routines and saves you time and frustration. Microsoft Flow has over 170 connectors, including Dynamics 365, and it has capabilities which complement those of the in-app Dynamics 365 workflow editor.

Today we’ll talk about one exciting feature. Microsoft Flow has an action called ‘apply to each’ which can loop through a set of records on the many side of a one-to-many of a relationship and interact with each of them. Let’s see how it works.

We have a business requirement that when the Main Phone number of an account changes, we want to copy the account Main Phone number into the Company Phone field for all the related contacts. In the past this would have required code because with a one-to-many relationship, like that of accounts to their related contacts, Dynamics 365 workflow processes cannot access existing records on the many side when the workflow is triggered from a record on the one side. The great news is now we can do this with Microsoft Flow!

Summary of steps:

  • Create a flow which will trigger when an account record is updated in Dynamics 365
  • Create an action which uses an OData filter query to list all of the active contacts related to the account which triggered the flow
  • Create an action inside a for each container which updates each contact with a value from the account

Considerations:

  • The Flow for Dynamics 365 plan includes 2000 runs per month (aggregated for all users), unlimited flow creation and 5-minute checks. For more flow runs, faster checks, premium connectors and management options, see Microsoft Flow pricing.
  • The user who creates the flow must have necessary permissions in Dynamics 365.
  • Any update on the record will trigger the flow, there is no filtration at this point.

Let’s get started:

Sign in to the Microsoft Flow website.

Click or tap My flows, and then click or tap Create from blank.

092818 2145 UseMicrosof1 Use Microsoft Flow with Dynamics 365 for Customer Engagement

In the list of flow triggers, click or tap Dynamics 365 – When a record is updated. (If prompted, sign in to Dynamics 365.)

(Hint: Start typing in the search box and wait a few seconds to see a filtered list of options.)

092818 2145 UseMicrosof2 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Under Organization Name, select the Dynamics 365 instance where you want the flow to
listen.

(IMPORTANT: In order for the flow to trigger on the Dynamics 365 entity, the entity definition should have Change Tracking enabled.)

Under Entity Name, select the entity that you want to listen to, which will act as a trigger initiating the flow. For this walkthrough, select Accounts.

(Consider: This flow will run each time anything on an account is changed, which will count against the allotted number of runs in your Flow plan.)

092818 2145 UseMicrosof3 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Click or tap New step, and then click or tap Add an action.

Click or tap Dynamics 365 – List records.

092818 2145 UseMicrosof4 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Under Organization Name, select the same Dynamics 365 instance as the trigger.

(Note: Because we want to list contacts related to the account which triggered the flow, we choose the same Dynamics 365 instance where the event is triggered from. For other types of actions, such as create a new record, it doesn’t have to be the same instance where the event is triggered from.)

Under Entity Name, select the entity from which to list records when the event occurs. For this walkthrough, select Contacts.

Click or tap Show advanced options

092818 2145 UseMicrosof5 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Click or tap Filter Query. A dynamic content pane appears where you can select fields from previous steps. We can use an OData query to filter the list to active contacts related to the account which triggered the flow.

  • Enter the text statuscode eq 1 and _parentcustomerid_value eq
  • From the dynamic content pane, select Account (Description: Unique identifier of the account.)

092818 2145 UseMicrosof6 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Click or tap New step, and then click or tap Add an action.

Click or tap Dynamics 365 – Update a record.

092818 2145 UseMicrosof7 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Under Organization Name, select the same Dynamics 365 instance as the previous action.

Under Entity Name, select the entity that will update a record when the event occurs. For this walkthrough, select Contacts.

Click or tap Show advanced options.

092818 2145 UseMicrosof8 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Scroll down and click or tap Company Phone. From the dynamic content pane select Main Phone (Description: Type the main phone number for this account.)

(Hint: You can search for words from either the field name or the field description.)

092818 2145 UseMicrosof9 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Scroll up and click or tap Record Identifier. From the dynamic content pane select Contact (Description: Unique identifier of the contact.)

092818 2145 UseMicrosof10 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Notice that Microsoft Flow automatically nests the Update a record step inside an Apply to each step (also called a for each container). The Apply to each action must reference output from a previous step and Microsoft Flow has automatically populated this with the dynamic content value which refers to the records from the List records step.

(Note: Instead of creating the Update a record action first, as we did in this walkthrough, you could first add and configure the Apply to each action and then add and configure a nested Update a record action.)

092818 2145 UseMicrosof11 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Click Save.

092818 2145 UseMicrosof12 Use Microsoft Flow with Dynamics 365 for Customer Engagement

Make a change to an account in Dynamics 365 and test your flow. Microsoft Flow changed all of the contacts related to the account so you didn’t have to!

Be sure to subscribe to the PowerObjects blog for more great Dynamics 365 and Microsoft biz apps content!

Happy Dynamics 365’ing!

Let’s block ads! (Why?)

PowerObjects- Bringing Focus to Dynamics CRM

customer, Dynamics, engagement, Flow, Microsoft
  • Recent Posts

    • NOT WHAT THEY MEANT BY “BUILDING ON THE BACKS OF….”
    • Why Healthcare Needs New Data and Analytics Solutions Before the Next Pandemic
    • Siemens and IBM extend alliance to IoT for manufacturing
    • Kevin Hart Joins John Hamburg For New Netflix Comedy Film Titled ‘Me Time’
    • Who is Monitoring your Microsoft Dynamics 365 Apps?
  • Categories

  • Archives

    • February 2021
    • January 2021
    • December 2020
    • November 2020
    • October 2020
    • September 2020
    • August 2020
    • July 2020
    • June 2020
    • May 2020
    • April 2020
    • March 2020
    • February 2020
    • January 2020
    • December 2019
    • November 2019
    • October 2019
    • September 2019
    • August 2019
    • July 2019
    • June 2019
    • May 2019
    • April 2019
    • March 2019
    • February 2019
    • January 2019
    • December 2018
    • November 2018
    • October 2018
    • September 2018
    • August 2018
    • July 2018
    • June 2018
    • May 2018
    • April 2018
    • March 2018
    • February 2018
    • January 2018
    • December 2017
    • November 2017
    • October 2017
    • September 2017
    • August 2017
    • July 2017
    • June 2017
    • May 2017
    • April 2017
    • March 2017
    • February 2017
    • January 2017
    • December 2016
    • November 2016
    • October 2016
    • September 2016
    • August 2016
    • July 2016
    • June 2016
    • May 2016
    • April 2016
    • March 2016
    • February 2016
    • January 2016
    • December 2015
    • November 2015
    • October 2015
    • September 2015
    • August 2015
    • July 2015
    • June 2015
    • May 2015
    • April 2015
    • March 2015
    • February 2015
    • January 2015
    • December 2014
    • November 2014
© 2021 Business Intelligence Info
Power BI Training | G Com Solutions Limited