I have a personnel data sheet that contains names of employees in column C of sheet named awards_civic_length_of_service.
Usually like - Jones, Bob E JR
Due to inconsistencies of spaces during input I use this formula in A2 of sheet 2 to bring the names into my data.
=SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(awards_civic_length_of_service_!C2,", "," "),"JR"," JR"),"II"," II"),"III"," III"),"SR"," SR")
I then extract the first name, middle initial, last name and suffix into columns B, C, D, E of sheet 2
It works great with one exception and I cannot figure out why.
Column D of sheet 2 contains this formula.
=TRIM(MID(SUBSTITUTE(A2," ",REPT(" ",100)),300,100))
But Column D will not show my JR's and SR's and II's and III's unless I go to the original awards_civic_length_of_service and rid myself of ALL spaces between the middle initial and the suffix.
So the name looks like - Jones, Bob EJR
Any idea why I have to remove those spaces completely?
Usually like - Jones, Bob E JR
Due to inconsistencies of spaces during input I use this formula in A2 of sheet 2 to bring the names into my data.
=SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(awards_civic_length_of_service_!C2,", "," "),"JR"," JR"),"II"," II"),"III"," III"),"SR"," SR")
I then extract the first name, middle initial, last name and suffix into columns B, C, D, E of sheet 2
It works great with one exception and I cannot figure out why.
Column D of sheet 2 contains this formula.
=TRIM(MID(SUBSTITUTE(A2," ",REPT(" ",100)),300,100))
But Column D will not show my JR's and SR's and II's and III's unless I go to the original awards_civic_length_of_service and rid myself of ALL spaces between the middle initial and the suffix.
So the name looks like - Jones, Bob EJR
Any idea why I have to remove those spaces completely?
Last edited: