web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Suggested Answer

Each code on account

(0) ShareShare
ReportReport
Posted on by 235

Hi, I have created new each code to merge a field

from an related entity from

account. The code I have created shows no errors, but I Am not able to see anything when I am sending the email... It’s just empty even though I know there is data in the field I am trying to show.. 

Any idea what that can be? 

kind regards

camilla 

I have the same question (0)
  • cloflyMao Profile Picture
    25,210 on at

    Hi Camilla,

    Could you share me your code?

    As per my understanding, were you trying to get related records of parent account(company name field) of contact?

    For example: show other contacts of the parent account in content of marketing email.

    Regards,

    Clofly

  • Camilla Larsson Profile Picture
    235 on at

    Hi,

    Yes I am trying to show data from a related record  from an account. This is the code I have.

    {{#each contact.new_chargingchip_contact_new_chipownerforcompanymember}}

    {{this.new_name}}

    {{/each}}

    Kind Regards

    Camilla

  • Suggested answer
    cloflyMao Profile Picture
    25,210 on at

    Hi Camilla,

    Sorry for the late response, I came back to work the day before yesterday.

    I created a custom entity called "Charging Chip", and added a lookup field "Chip Owner For Company"(Contact) to the entity.

    In addition to enable the entity in marketing data configuration, please check whether the "Change tracking" option of the entity was also checked, and try putting the name value within p tag.

    {{#each contact.new_chargingchip_contact_new_chipownerforcompanymember}}
    

    {{this.new_name}}

    {{/each}}

    pastedimage1602211766672v1.png

    Regards,

    Clofly

    Regards,

    Clofly

  • Camilla Larsson Profile Picture
    235 on at

    Thank you Clofly.

    I will try this

    Camilla

  • Oseirf Profile Picture
    67 on at

    Hello Everybody,

    We are  using both dynamics 365 Marketing and Sales. What I'm trying now is to get the "Owner-Fullname" of an opportunity inside an E-Mail:

    {{#each contact.opportunity_contact_customerid}}</li>

             <li>Verkaufschance Name: {{this.name}}</li>    <<- Works

             <li>Verkaufschance Offerte Versendet am: {{this.sendDate_offer}}</li>   <<-Works

             <li>Verkaufschance Besitzer: {{this.opportunity_systemuser_owninguser.fullname}}</li>  <<--Does not Work: Error: too many hops

    <li>{{/each}}    

    But if I select a "Static" Opportunity it works:

    {{opportunity(2558eaf4-3b14-45cd-9d94-6d4dce56c82231a).opportunity_systemuser_owninguser.fullname}}
    Any hints?
    KR
    Frieso

                             

  • cloflyMao Profile Picture
    25,210 on at

    Hi Frieso,

    We can have, at most, two hops (periods) in our field expressions.

    Even though {{this.opportunity_systemuser_owninguser.fullname}} has only two hops, but it could be regarded as {{contact.opportunity_contact_customerid.opportunity_systemuser_owninguser.fullname}}, which has three hops.

    In simple terms, fullname of  associated opportunities' owner is too far away from contact entity, only attribute of directly related entity of contact is supported to be added.(e.g: {{this.name}})

    The issue you encountered is similar to question of the following thread:

    https://community.dynamics.com/365/marketing/f/dynamics-365-for-marketing-forum/370438/marketing-email-assistant-can-not-show-lookup-field-name

    A community member has created an idea in Ideas forum that requesting support for more hops in email, you could vote on it.

    https://experience.dynamics.com/ideas/idea/?ideaid=0adb09f7-1f13-eb11-8441-0003ff68a0b0

    Regards,

    Clofly

  • Oseirf Profile Picture
    67 on at

    Hi Clofly

    thanks for your answer - what a pity with the "3 Hops". Hope this is implemented soon.

    Do you know if it's possible to "substring" some values? Facing the "3 hops" problem I could substring from a combined field some needet value.

    The datamodel is:

    <Customer> - <Connection> - <Role>

    In the table <Connection> I have a field "Name" where the value is in the format "<customerName> - <RoleName>" so if I could "substring" find the "-" in the value an then get the RoleName I have my 3rd hope by accessing this combined value.  

    Is there something like {{#substr (this.Name, XXXX) }} ??

    Regards

    Frieso

  • cloflyMao Profile Picture
    25,210 on at

    Hi Frieso,

    I am afraid that substr is not available.

    Dynamic expression of marketing email is implemented from Handlebarsjs and only 'if' and 'each' helpers are supported.

    https://handlebarsjs.com/guide/builtin-helpers.html

    However, due to javascript is not supported by marketing email, therefore, we couldn't add custom helper.

    Regards,

    Clofly

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
ManoVerse Profile Picture

ManoVerse 202 Super User 2026 Season 1

#2
CU11031447-0 Profile Picture

CU11031447-0 100

#3
NeerajPawar Profile Picture

NeerajPawar 70

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans