![]() |
#1 |
Участник
|
atinkerersnotebook: Using Functions within Flow using the Compose Action
Источник: https://atinkerersnotebook.com/2017/...ompose-action/
============== Flow is great, and just being able to point and click to build integrations is the thing that makes it so usable. But sometimes you want to be a little bit cleverer with your data and even use functions that remodel the data. For example, when creating a new Customer within Dynamics 365 for Operations through Flow when a new Account is created in the Common Data Service, if you are like me, then maybe you will want to have a consistent naming convention, and you don’t want to use the standard Account ID that is created in the entity. My customer naming convention is the first two letters of the Organization Name and then 4 digits, but I cannot change the default numbering format for the Account Id in the Accounts entity. If I were doing this through Excel, then I would use this formula: Upper(Left(OrganizationName)) & Right(AccountId,4) But how do you do this in Flow? The good news is that there is a special Data Operations service within Flow that allows you to create a function using data from the previous steps in the flow, and then you can use the output in subsequent steps. Here is how you do it. How to do it… To start off open Flow and then create a new Flow by clicking on the + Create from blank link. ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() https://docs.microsoft.com/en-us/azu...ition-language ![]() “@concat(toUpper(substring(triggerBody()[‘OrganizationName’],1,2)),substring(triggerBody()[‘AccountId’], sub(length(triggerBody()[‘AccountId’]),4), 4))” ![]() ![]() ![]() ![]() Now that we have composed our new field we can now use it in future steps within the Flow. For example if you continue on and add another action that created the Customer within Dynamics 365 for Operations, but when populating the Customer Number field, we can now use the output of the Compose action. How cool is that? (Rhetorical question) ![]() Источник: https://atinkerersnotebook.com/2017/...ompose-action/
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору. |
|
|
|