Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Convert to title case w/o impacting acronyms in parentheses

hellyars
13 - Pulsar

I have a field that is a mix of all upper case and title case.  I want to convert it to title case only.  BUT, there are acronyms throughout.  Sometimes these are at the end, sometimes these are in the middle of the text field in question.  

 

How can I convert everything to title case w/o impacting what falls between parentheses () or brackets [] -- because those are thrown in a few times just to drive me crazy.

 

EXAMPLE:   

 

FANCY BLUE BIKE (FBB)Fancy Blue Bike
NICE INTERESTING SPEEDY THING (NIST) ENGINEERING Nice Interesting Speedy Thing (NIST) Engineering

 

 

Thanks.

4 REPLIES 4
hellyars
13 - Pulsar

I could parse the acronyms out, convert case, and join the cells back together.  But, that would cause problems for those entries that have acronyms that appear in the text instead of at the end. 

Jonathan-Sherman
15 - Aurora
15 - Aurora

Hi @hellyars,

 

Could this work for you?

 

Input:

image.png

 

 

Output:

 

image.png

 

If this solves your issue please mark the answer as correct, if not let me know! I've attached my workflow for you to download if needed.

 

Regards,

Jonathan

hellyars
13 - Pulsar

@Jonathan-Sherman   This works perfectly in the test case.  I suspect it will work in the real-world.  I just have to be careful inserting it into the workflow.  Thanks.

Jonathan-Sherman
15 - Aurora
15 - Aurora

Hi @hellyars,

 

I've just edited the original attachment to take into account of non-letter characters, for example commas and full stops. I've attached it again here just in case.

 

Regards,

Jonathan

Labels