I have a lookup field of Account in the object Lead -- Hotels__c I have also a lookup field of Contact in the object Lead -- Applicant__c

When trying to merge the {!Account.Name} in the HTML Email template, the Contacts' Account (Applicant__c.AccountId) is getting instead of the Hotels__c. Why is that? Thanks in advance.

  • 1
    Are you trying to merge Lead fields? If yes, you should be using this: {!Lead.Hotels__c} to get the respective Hotels__c value.
    – Arnold Jr.
    Jul 21, 2017 at 4:44
  • @ArnoldJr. yeah. But i've want to get the address of that Lead.Hotels__c. When I'm trying to get, Lead.Hotels__r.ShippingAddress, the ShippingAddress was removed in the email template and it was replaced as Lead.Hotels__c by salesforce.
    – JMRAF69
    Jul 21, 2017 at 6:27

2 Answers 2


This issue is a Salesforce known issue. The workaround at this moment: You have to create a Formula field on the Child object, i.e, Leads to capture the field value from the Parent object that you wanted to display in the Email template.


Salesforce Success Community

Salesforce Idea

  • Jr Has this idea been implemented yet by Salesforce?
    – Student
    Jan 4, 2019 at 21:49
  • Nope. Not that I know of. Looks like the Idea is under consideration.
    – Arnold Jr.
    Jan 4, 2019 at 23:00

@JMRAF69, You can get shippingAddress field directly You have to call {!Lead.Hotels__r.ShippingCity}, {!Lead.Hotels__r.ShippingCountry}, {!Lead.Hotels__r.ShippingPostalCode} etc.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .