Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Answered

How to get lookup name instead of id in send an email action in Ms Flow

(0) ShareShare
ReportReport
Posted on by 393

Hi, 

I have a custom entity Lease. This lease entity contains the many lookups like user's and account.

I have created  Ms flow in which I am sending an email and I want to get the all lookup's name in the email body but as flow is triggered I am just getting the lookup's Id's.

I am using this expression in which I got the Id:- triggerOutputs()?['body/_cyno_primaryclientcontact_value'] 

and If I use:- triggerOutputs()?['body/_cyno_primaryclientcontact_value@OData.Community.Display.V1.FormattedValue'] then got nothing.

  • Himanshu Kamboj Profile Picture
    393 on at
    RE: How to get lookup name instead of id in send an email action in Ms Flow

    Thanks Leah!!

  • Verified answer
    Community Member Profile Picture
    on at
    RE: How to get lookup name instead of id in send an email action in Ms Flow

    Hi Himanshu,

    Maybe you can add one action ‘Get a row by ID’ action before get lookup field name.

    For example, I test I contact entity, which have one lookup field named ‘Account name’ related to account entity.

    1.Firstly, I tested it as your example, then I got the same results with you.

    triggerOutputs()?['body/_parentcustomerid_value'] can get id.

     pastedimage1620031854100v1.png

    triggerOutputs()?['body/_parentcustomerid_value_parentcustomerid_value@OData.Community.Display.V1.FormattedValue'] get nothing

    pastedimage1620031870499v2.png

    2.Then i add one  action ‘Get a row by ID’  with guid from the trigger, and use 

    outputs('Get_a_row_by_ID')?['body/_parentcustomerid_value@OData.Community.Display.V1.FormattedValue']
    pastedimage1620032103986v3.png
    Test Result:
    pastedimage1620032155400v4.png

    Regards,

    Leah Ju

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

🌸 Community Spring Festival 2025 Challenge 🌸

WIN Power Platform Community Conference 2025 tickets!

Jonas ”Jones” Melgaard – Community Spotlight

We are honored to recognize Jonas "Jones" Melgaard as our April 2025…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 294,127 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 232,871 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,158 Moderator

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans