0

I want to define a formula field to have the value of the Name field of a lookup field. I tried something like this:

Lead__r.Name

where "Lead" is a lookup field pointing to a lead. However, the formula builder complains that "Name is not a field". When I use "Insert Field", and click on the Lead lookup field, it shows me all the expected fields on Leads except Name. Is there something special about Name? What am I missing?

enter image description here

1 Answer 1

1

Lead's don't have a Name field like most other objects, the only way to get the full name is to manually combine the FisrtName and LastName in your formula:

Lead__r.FirstName & " " & Lead__r.LastName
2
  • Thank you. In that case, what is the meaning of the "Name" field documented at developer.salesforce.com/docs/…?
    – kamezaburo
    Commented Sep 4, 2020 at 17:52
  • Salesforce uses that field when displaying leads (in relationship fields or list views etc.), and the Name field is accessible in code, it's just not accessible in formula fields
    – Instread
    Commented Sep 4, 2020 at 18:08

You must log in to answer this question.

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