June 24, 2018
Hi My Online Training Experts,
Hope you are all safe and well. I think you looked at this before, not sure if you did, but I need to add a few things to the text string in the A column. Can you adjust the formulas so it would add a Title in the first column? When I added the title column everything gets all jumbo up. Also, can you add a hyphen in between the two last names? And a comma between last name and Jr., II, III, etc. Not sure if you can do those things in the same column. Thanks for your help. Joe from Michigan.
Trusted Members
December 20, 2019
You data isnt in the best format for this type of work.
As a bodge you could use =IFERROR(IF(SEARCH(".",A14)<5,LEFT(A14,SEARCH(".",A14)),""),"") to get a title, but its not perfect
We can find the end of the last name with this =AGGREGATE(15,6,SEARCH({0,1,2,3,4,5,6,7,8,9},A14),1), but then we get a problem with not knowing if they have a double barrelled name, a middle name/initital or a suffix.
You can get a first name (more or less) with =LEFT(C14,SEARCH(" ",C14))
I dont think you can ever get this perfect, so i would go with =TRIM(MID(A14,LEN(B14)+1,AGGREGATE(15,6,SEARCH({0,1,2,3,4,5,6,7,8,9},A14),1)-LEN(B14)-1)) to find thier whole name
Purfleet
VIP
Trusted Members
December 7, 2016
Hello,
A few suggestions, depending on how the data is coming in to this Excel file.
If typed in then it is of course better and easier to type the data direct to related column.
If imported from a text file, then a comma separated list of data would be good.
If pasted in from another source and if you are able to decide the format, I suggest a comma separated format.
Example:
Title, First name, Middle name, Last name, Address, Town, State, Zip
Ms., Ann, , Mullins Horling, 18794 Jamestown Circle, Northville, Michigan, 48168
With a comma separated list you know that the comma is the character that separates the data. You can use whatever character you want as a separator, the comma is more or less the standard. Having a mixed set of characters as separators as shown in your sample file makes things more difficult.
If you are importing the data from files, text or other Excel files, then I suggest you use Power Query. Here you can read more on how to start using PQ.
Br,
Anders
The following users say thank you to Anders Sehlstedt for this useful post:
Purfleet1 Guest(s)