This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
How would I convert a string of numbers 3037777777 into a classic phone number format: 303-777-7777. I know you can accomplish this in excel through the following function =REPLACE(REPLACE(A2,4,0,"-"),8,0,"-"). Is this something I can accomplish in Alteryx using RegEx or another expression I'm unaware of right now? Thanks for any help you can give me
I have a data set that has a data string (data set 1) such as contract number. I join it with another data set that has the same contract number but with " - " between certain characters in the data set. I need to be able to convert the data in data set 1 to add "-" between certain characters in order to be able to have the data fields matching each other. ie; data set 1 contract number converted to look like data set 2 contract numbers.
In data set 1, the contract appears as such: 1910081 or 19102521
In data set 2, the contract appears as such: 19-100-81 or 19-1025-21
(two examples of contracts)
What tools and or formulas can I use in order to convert the text in data set 1 to appear with same formatting "-" and all, same as data set 2
Please note, that in both cases, I need to add a "-" after the first two characters and also a "-" before the last two characters. The middle characters in the case of both examples (can be either 3 or 4 characters) must remain the same also.