Hi. I am using a formula to clean up Title Case from cleansing tool of last names. It works great except for names like McDonald, MacDonald, DeLeon, etc. I have this formula found in the community:
if contains([Last Name], "-") then Replace(TitleCase(ReplaceChar([Last Name], "-", '$')), '$',"-")
elseif contains([Last Name], "'") then Replace(TitleCase(ReplaceChar([Last Name], "'", '$')), '$',"'")
elseif contains([Last Name], "Mc") then Replace(TitleCase(ReplaceChar([Last Name], "Mc", '$')), '$', "Mc")
else TitleCase([Last Name]) endif
The results from:
JOHN WHITE-JONES
TIMOTHY O'LEARY
JACK MCCLUNG
Along with Cleanse to Title Case only on first name gets me this:
John White-Jones (correct)
Timothy O'Leary (correct)
Jack McCclung (incorrect - should be Jack McClung)
Any suggestions? I know there are Van Horns, DeLeone, MacDonald, De Leone, etc. to consider, but most of my names are hyphens, apostrophes, and Mc.
Also, used McClung because of the challenge of getting to that second C to be upper case.
Thanks.