Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.
Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

How to convert text to title case and keep acronyms capitalized

hellyars
13 - Pulsar

How can I convert names to the Title Case AND keep acronyms enclosed in parentheses capitalized. 

 

This is a single example. There are thousands of records.

 

START

END GOAL

GUIDED MLRS ROCKET (GMLRS)

Guided MLRS Rocket (GMLRS)

3 REPLIES 3
kat
12 - Quasar

Hi @hellyars

 

It wouldn't be possible to identify and keep acronyms capitalised within the text, as how would one know what MLRS is an acronym and GUIDED is not. It is however possible to do it for the acronym in brackets, as per the attached.

 

acronyms.PNG 

 

Only thing I could recommend for the other acronyms is a find and replace, assuming you have a list of all of them.

 

Hope this helps!

Kat

hellyars
13 - Pulsar

It totally helps.  The majority of acronyms are in parenthesis.  Thank you

Thableaus
17 - Castor
17 - Castor

Hi @hellyars

 

I was playing with RegEx to help you out and also found a way of avoiding titlecasing the word inside parenthesis.

 

Using RegEx, on Replace Method

 

(?<![\(\w])(\w)(\w+)

 

Replacement: $1\L$2

 

Cheers,

Labels
Top Solution Authors