How to get field name from previous step using expression in Power flow or Microsoft Flow

 

How to get field Name from previous step by using Expression when we use GetRecordByID trigger in power flow:

There is no direct option in Power flow to get all columns or selected columns when we are triggering the flow from OOB button click. Ie “When a record is selected” trigger.

Output from the above trigger. Click on “Show raw output” . This option you will get once the flow was run. Below we can see only “accountid” field from in the Output window below.



But we can achieve it using another way.

1.       Create a “When a record is selected” trigger


1.       Add another action “Get Record By ID” from dataverse. Here I have selected name and emailaddress1 column.




1.       Take another action “Variable”. Declare it as “AccountName”.



Here I want to capture the account record “name” field using expression. For that I need to use below expression.

Body(‘GetRecordByID’)[‘name’]


Here “GetRecordByID” I my previous action name which is highlighted in below picture in yellow colour. And ‘name’ is Account entity field. This is how we need to use expression to get field name from any previous step.








Comments

Popular posts from this blog

Connecting Dynamics 365 Web api using external HTML page

Get azure blob files inside Sub Directories

Interview questions on MS CRM