How can I get the account name, phone number, and address to populate in an opportunity Lightning email template - Answers - Salesforce Trailblazer Community
Trailblazer Community
Ask Search:
Beverly TyreeBeverly Tyree 

How can I get the account name, phone number, and address to populate in an opportunity Lightning email template

Hi,

I am trying to create a Lightning email template that pulls information from the Opportunity to send for an RFQ. I have tried a number of ways to pull the account name, phone number, and address into the template from the Opportunity object without success. Is there anyway to do this? Thank you.

Here is the syntax I have used. 

Please see details for RFQ below.

Quote Type: (Select one/delete all others not applicable)
Electrical Only
Mechanical Only
Electrical & Mechanical
Fabrication
T&M
Service

Product of Interest: {{{Opportunity.Products_of_Interest__c}}}

Client Number: {{{Opportunity.Account_Number}}}
Client Name:{{{Opportunity.Account_Name}}}
Client Address:{{{Opportunity.Account_Address}}}

Primary Contact Name: {{{Opportunity.Primary_Contact_Name__c}}}
Primary Contact Phone:{{{Opportunity.Primary_Contact_Phone__c}}}
Primary Contact Email: {{{Opportunity.Primary_Contact_Email__c}}}
SF Opportunity Name: {{{Opportunity.Name}}}
Quote Due Date: {{{Opportunity.Quote_Due_Date__c}}}
Sales Rep: {{{Opportunity.OwnerFullName}}}

Description: {{{Opportunity.Description}}}

Thanks, and let me know if you have any questions.

{{{Opportunity.OwnerFullName}}}
Best Answer chosen by Beverly Tyree
John KnightJohn Knight
Hi Beverly, unfortunately, you cannot lookup across objects in an email merge field.  The workaround is to create formula fields on the opportunity object to pull in all the fields you need from the account.

All Answers

John KnightJohn Knight
Hi Beverly, unfortunately, you cannot lookup across objects in an email merge field.  The workaround is to create formula fields on the opportunity object to pull in all the fields you need from the account.
This was selected as the best answer
Beverly TyreeBeverly Tyree
Thanks, John, for the info. That is what I thought but was hoping there was another solution. Now to build these out.
John KnightJohn Knight
Keep hoping.  Maybe they'll build that functionality someday.

Here's an idea to upvote in the mean while: https://success.salesforce.com/ideaView?id=08730000000Brk7AAC