Parsing the last name from a name string

  • Thread starter Thread starter Dan
  • Start date Start date
D

Dan

I am using the Right function to extract the last name but
what nested function do you use to count the number of
characters in the last name?
 
Hi, Dan,
I am using the Right function to extract the last name but
what nested function do you use to count the number of
characters in the last name?

I think this is what you're after:

=RIGHT(A1, LEN(A1)-SEARCH(" ",A1))

It assumes there is just one space in the name, so middle names or
initials, or titles in some names, etc., could be problematic. But
it's a start.

Peace,
--Carl
 
LEN

eg =len("coombs") would return 6. Alternatively =LEN(A1) would also return
6 if coombs was in cell A1.

Cheers,
Katherine
 
...
...
=MID(A1,FIND(" ",A1)+1,255)

Where 255 is just a sufficiently large number to capture text to the
right of the space.
...

And if the arbitrary constant offends one's sensibility, there's always

=REPLACE(A1,1,FIND(" ",A1),"")

with the same number of function calls but the 1 here is less arbitrary than the
255 above. TMTOWTDI
 
Back
Top