Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 75
Default Need some help with name replacement type formulas

I am having some difficulties getting this to work, but here is what I have;

for arguments sake, we will say the first name is John, last name Doe,
middle initial X. I have a list of 200 names that look like this, that do me
no good in this format.

Doe, John
Doe, John X
Doe, X John

Now I can get a formula that resolves the first one:
=CONCATENATE(RIGHT(H2,LEN(H2)-FIND("*",SUBSTITUTE(H2,"
","*",LEN(H2)-LEN(SUBSTITUTE(H2," ","")))))&" "&LEFT(H2,FIND(" ",H2)-1))

However as you can probably tell, this falls apart on the second and third
names...I need a formula that will fix both of them...and I cant quite seem
to get it right. I know its gotta be a simple factor of an IF statement, I
just can't get the math right as I am not very good with these types of
functions =(


  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
CLR CLR is offline
external usenet poster
 
Posts: 1,998
Default Need some help with name replacement type formulas

Have you considered using Data TextToColumns using Comma as the
delimiter.......then you can do it again on the second column using space as
the delimiter......then the concatenation to re-construct the names should be
much easier......

Vaya con Dios,
Chuck, CABGx3



"havocdragon" wrote:

I am having some difficulties getting this to work, but here is what I have;

for arguments sake, we will say the first name is John, last name Doe,
middle initial X. I have a list of 200 names that look like this, that do me
no good in this format.

Doe, John
Doe, John X
Doe, X John

Now I can get a formula that resolves the first one:
=CONCATENATE(RIGHT(H2,LEN(H2)-FIND("*",SUBSTITUTE(H2,"
","*",LEN(H2)-LEN(SUBSTITUTE(H2," ","")))))&" "&LEFT(H2,FIND(" ",H2)-1))

However as you can probably tell, this falls apart on the second and third
names...I need a formula that will fix both of them...and I cant quite seem
to get it right. I know its gotta be a simple factor of an IF statement, I
just can't get the math right as I am not very good with these types of
functions =(


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 75
Default Need some help with name replacement type formulas

Yes that worked for the most part, but was much easier to clean up afterwards
=)


"CLR" wrote:

Have you considered using Data TextToColumns using Comma as the
delimiter.......then you can do it again on the second column using space as
the delimiter......then the concatenation to re-construct the names should be
much easier......

Vaya con Dios,
Chuck, CABGx3



"havocdragon" wrote:

I am having some difficulties getting this to work, but here is what I have;

for arguments sake, we will say the first name is John, last name Doe,
middle initial X. I have a list of 200 names that look like this, that do me
no good in this format.

Doe, John
Doe, John X
Doe, X John

Now I can get a formula that resolves the first one:
=CONCATENATE(RIGHT(H2,LEN(H2)-FIND("*",SUBSTITUTE(H2,"
","*",LEN(H2)-LEN(SUBSTITUTE(H2," ","")))))&" "&LEFT(H2,FIND(" ",H2)-1))

However as you can probably tell, this falls apart on the second and third
names...I need a formula that will fix both of them...and I cant quite seem
to get it right. I know its gotta be a simple factor of an IF statement, I
just can't get the math right as I am not very good with these types of
functions =(


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to Evaluate Dynamic DDE Formulas MArcus Baffa Excel Worksheet Functions 5 September 12th 06 10:35 PM
Cant find & delete invalid formulas or links Ramon Gavin Excel Discussion (Misc queries) 3 December 8th 05 02:45 PM
Printing formulas TUNGANA KURMA RAJU Excel Discussion (Misc queries) 7 November 28th 05 07:29 AM
copy worksheet to a new workbook with formulas .... but new file not point to old one newToExcel Excel Discussion (Misc queries) 7 November 13th 05 09:55 PM
Database type Formulas Smejk Excel Worksheet Functions 1 August 29th 05 12:13 PM


All times are GMT +1. The time now is 09:33 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"