function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Medhanie HabteMedhanie Habte 

Trim first blank space in Contact Full Name Formula

Greetings, I have a formula field in my Salesforce instance that concatenates the contact records first and last names FirstName & LastName. Some of my contacts do not have first names, in the full name formula both fields are taken into account and thus a contact with a last name in this field would appear as " Friend" rather than "Friend." I am wondering if there is a solution to trim the first space in the field.

Hope it helps.
Best Answer chosen by Medhanie Habte
Shyama B SShyama B S
What is the formula you used?
I tried with the below formula and I didn't face the problem you mentioned:
FirstName + ' ' + LastName

Thanks.

All Answers

PalapalaPalapala
TRIM(FirstName) and replace text with the field or expression you want to trim. [Removes the spaces and tabs from the beginning and end of a text string]
Shyama B SShyama B S
What is the formula you used?
I tried with the below formula and I didn't face the problem you mentioned:
FirstName + ' ' + LastName

Thanks.
This was selected as the best answer
Medhanie HabteMedhanie Habte
Actually, I figured it out IF(FirstName = " ",LastName,First Name+' '+LastName)