Wednesday, November 18, 2020

MS Flow to update records in D365 CRM

 

Recently we had a requirement to add one new flag in Product entity. Once flag added, I need to update some of the products based on some criteria. But to update products either I need to open each product and update flag or need to find some another way. So, I thought of writing my first power automation flow.

This is just one-time update job, so I created manually trigger flow.

In this flow I used fetch xml query to pull products which I want to update and used for each (Apply to Each) loop to update product.

  •    Start creating flow from blank

·       In Manual trigger a flow, I used to Yes/No input for just confirmation about executing flow.



  •     So far, we are not connected to Common data service. To pull data from D365, you need to connect to D365 using common Data Service and choose environment.   Once Connected to D365, use List Records Action in Common Data Service.



    ·       For List Records Action you need to specify Entity name and there are different options to retrieve records. I used FetchXml.



    ·       Now there are many records and need to update one by one. When using workflow in D365 CRM we cannot update one-by one record in single workflow until we write some custom code. But now in power automation you can using basic loops like Apply to Each.



    ·       Apply to Each loop is a For Each loop.  Which will give you each item. Here we are pulling products and passing to Loop, so need to get each product. In Select an output from previous steps, select list value. Which is a single product value.



    ·       Now we need to work in Loop. Click add Action in Loop and use Common Data Service  à Update Record.

    ·       In Update Record action, use entity name as Product and then Item Id will be Product Unique Identifier. And then need to set attributes whose values need to be updated.



Complete flow will look like





10 comments:

  1. Thanks for this information. Keep sharing informative post like this. Please check our website for all new articles.Economic Substance Regulations UAE

    ReplyDelete
  2. Best and very informative article. keep sharing article like this. very useful one. Thanks for sharing this article. please check our website for all new related article. Accounting Services in Dubai

    ReplyDelete
  3. Thanks for this wonderful blog. Best and very informative one. please check our website for all new article. ICV Certificate

    ReplyDelete
  4. Happy to read this article. very useful. please visit our website for all new article. Accounting and Bookkeeping Services in Dubai

    ReplyDelete
  5. I have a question: How do I solve it, when I want to update an Optionset in Dynamicvs CRM?

    ReplyDelete
  6. Nice blog! Blog is very informative and useful for everyone. BRJ provides completely secure and reliable CRMSoftware, has gained enough attention from the best industry experts and is still performing efficiently in providing one-stop solutions to various small and medium sized business houses.

    ReplyDelete
  7. I really appreciate for your efforts you to put in this article, this is very informative and helpful. I really enjoyed reading this blog. Keep sharing and give us updates.

    vehicle Acquisition

    ReplyDelete
  8. Casino de Sol - Dr.MCD
    Casino de Sol. Casino 군산 출장샵 de Sol. 김천 출장샵 All about it. This casino 남원 출장마사지 was 서귀포 출장안마 built in 1998 and was owned by 경상북도 출장마사지 Caesars Entertainment Corporation.

    ReplyDelete
  9. The blog was really helpful, thanks for such quality content
    automation of warehouse

    ReplyDelete
  10. Thank you for sharing the information with us. Besides if you need a repair service with your computer then ITFUX24 can help you. The company had a very good reputation with repairing service. Take the Computer Hilfe frankfurt service from them. And enjoy the discount from the first day!

    ReplyDelete