I have a custom object called Engagement__c that has Account__c. Account__c has a field called Name. The relationship between them is that Account__c is a lookup field in Engagement__c. I want to create a simple formula field in Engagement__c that gets the Name of Account__c.

Account Name (text):

Account__c //Works - no syntax error

Account__c.Name //ERROR - Field Account__c does not exist. Please check spelling

according to Understanding Relationship Names, Custom Objects, and Custom Fields

When you use a relationship name in a query, you must use the relationship names without the __c. Instead, append an __r (underscore underscore r).

so use Account__r.Name

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.