PC Review


Reply
Thread Tools Rate Thread

Converting middle name to middle initial

 
 
=?Utf-8?B?QmV2ZXJseQ==?=
Guest
Posts: n/a
 
      23rd Jan 2004
I am trying to create a formula where I can delete all the characters from the middle name except for the first one. This middle name is as follows in one cell:

Lastname, firstname, middle name. Can I use the upper function to do this-?--the middle names, of course, will be of variable length. With your help I have been able to identify whether the existing middle name is only an intial or a longer string.

=IF(EXACT(RIGHT(G2),UPPER(RIGHT(G2))),G2,"Need to figure this out still")

Thanks again for your help.
-Beverly
 
Reply With Quote
 
 
 
 
Jason Morin
Guest
Posts: n/a
 
      23rd Jan 2004
See if this works for you:

=LEFT(A1,FIND(",",A1,FIND(",",A1)+1))&" "&MID(A1,FIND
("#",SUBSTITUTE(A1," ","#",LEN(A1)-LEN(SUBSTITUTE
(A1," ",""))))+1,1)&"."

HTH
Jason
Atlanta, GA

>-----Original Message-----
>I am trying to create a formula where I can delete all

the characters from the middle name except for the first
one. This middle name is as follows in one cell:
>
>Lastname, firstname, middle name. Can I use the upper

function to do this-?--the middle names, of course, will
be of variable length. With your help I have been able to
identify whether the existing middle name is only an
intial or a longer string.
>
>=IF(EXACT(RIGHT(G2),UPPER(RIGHT(G2))),G2,"Need to figure

this out still")
>
>Thanks again for your help.
>-Beverly
>.
>

 
Reply With Quote
 
=?Utf-8?B?QmV2ZXJseQ==?=
Guest
Posts: n/a
 
      23rd Jan 2004
Hi Jason-
Thanks so much. I haven't quite gotten it to work yet----can you tell me why you use the "#"--oh maybe it's the number as the result of the "find" function. I will keep struggling with this--Thanks for giving me something to work with.

----- Jason Morin wrote: -----

See if this works for you:

=LEFT(A1,FIND(",",A1,FIND(",",A1)+1))&" "&MID(A1,FIND
("#",SUBSTITUTE(A1," ","#",LEN(A1)-LEN(SUBSTITUTE
(A1," ",""))))+1,1)&"."

HTH
Jason
Atlanta, GA

>-----Original Message-----
>I am trying to create a formula where I can delete all

the characters from the middle name except for the first
one. This middle name is as follows in one cell:
>>Lastname, firstname, middle name. Can I use the upper

function to do this-?--the middle names, of course, will
be of variable length. With your help I have been able to
identify whether the existing middle name is only an
intial or a longer string.
>>=IF(EXACT(RIGHT(G2),UPPER(RIGHT(G2))),G2,"Need to figure

this out still")
>>Thanks again for your help.

>-Beverly
>.
>

 
Reply With Quote
 
=?Utf-8?B?QmV2ZXJseQ==?=
Guest
Posts: n/a
 
      23rd Jan 2004
Jason-
Your formula works fine. My problem is that I told you that there was a comma after the first name (which there is not)--so I am working to adjust what you gave me.

lastname, firstname midinitial
Thanks
-Beverly
 
Reply With Quote
 
Jason Morin
Guest
Posts: n/a
 
      23rd Jan 2004
This should work:

=LEFT(A1,FIND(" ",A1,FIND(" ",A1)+1))&" "&MID(A1,FIND
("#",SUBSTITUTE(A1," ","#",LEN(A1)-LEN(SUBSTITUTE
(A1," ",""))))+1,1)&"."

Be aware that this will fail with names containing more
than 3 words such as De la Hoya, Oscar Benito.

HTH
Jason
Atlanta, GA

>-----Original Message-----
>Jason-
>Your formula works fine. My problem is that I told you

that there was a comma after the first name (which there
is not)--so I am working to adjust what you gave me.
>
>lastname, firstname midinitial
>Thanks
>-Beverly
>.
>

 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Sometimes there a middle initial Lori Microsoft Access Queries 5 25th Sep 2008 11:55 PM
match middle initial with middle name field =?Utf-8?B?Y2luZHk=?= Microsoft Access Queries 2 22nd Oct 2007 01:11 AM
Remove middle initial from "first name middle initial" =?Utf-8?B?SnVzdGluIEYu?= Microsoft Excel Misc 15 26th Sep 2005 06:13 PM
First name, Middle Initial =?Utf-8?B?d25maXNiYQ==?= Microsoft Excel Misc 2 21st Sep 2005 03:03 PM
Expression to middle name/initial from "Last, First Middle" =?Utf-8?B?VGlt?= Microsoft Access Queries 1 24th Jun 2005 06:28 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:52 AM.