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.
Your regular expression depends entirely on what pattern of characters that you are expecting. The below expression technically parses the data how you need, but only based on the number of characters. First column has one character, second column has 2, third has 5, etc. It would be helpful if you know the logic for how these fields should be split. Workflow is attached.
You've got several good solutions already, but seeing that you haven't marked them solved yet I will provide another. While I am a big fan of RegEx, I don't think that this challenge calls for pattern matching. I do favor using a FLAT definition, but here's a simple set of formulas:
The rest are substrings:
The 1st numeric argument is the starting position (zero based). So position #2 for a length of 2 actually becomes 1 for a length of 2.
Alteryx ACE & Top Community Contributor
Chaos reigns within. Repent, reflect and reboot. Order shall return.
There are other ways to write regular expressions depending on the pattern that your data has. In this case, the period signifies a character so having four periods would indicate four characters. The parenthesis defines a "group" which is going to be put into its own column.
There are ways, for instance, to say that you want to capture all of the numbers up until you hit a letter, or all of the letters until you hit a number. Some people will use sites like regex101.com or others to learn regular expressions because it is not just an Alteryx exclusive functionality.