Forum Discussion
HUSSIENASCANT
Sep 01, 2024Copper Contributor
Remove last name formula in excel
Hello,
I have column with some names like below I need formula to remove the last name only from them
John Smith
john Abraham smith
john john smith Abraham
I tried many formulas but the issue if it two names only it gives me value#
Let's say you have names in A2 and down.
In B2:
=IFERROR(TEXTJOIN(" ", TRUE, DROP(TEXTSPLIT(A2, " "), , -1)), A2)
Fill down.
- HUSSIENASCANTCopper Contributor
HansVogelaar Thanks it works perfectly