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

Alteryx Designer Desktop Discussions

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

Adding White Space after the second character - Help

Dpharr
6 - Meteoroid

I have a list of international phone numbers and the formatting is different with each. The only thing I need to do is add white space after the second character - For example

 

if the phone number is +916xxxxxxx - I need to insert a space so it reads +91 6xxxxxxx. Some numbers in my table are formatted in this fashion while others are not. Even though we are working with phone numbers the data type is V_WString. 

 

I'm running into a mental roadblock with something that should be simple. 

 

Thank you

3 REPLIES 3
JosephSerpis
17 - Castor
17 - Castor

Hi @Dpharr I came up with one approach on how to tackle this. Let me know what you think?

Dpharr
6 - Meteoroid

Perfect!

 

Thank your help

HomesickSurfer
12 - Quasar

Hi @Dpharr 

 

If you wish to conserve canvas space, runtime...or merely uncomfortable with RegEx, you may wish to use 2 formulas:

 

1)  Remove all whitespace

2)  Insert single space at 4th character position in the string

 

Capture.PNG

Labels