Hello
Could anyone help with the below?
Basically need to create a new column when a number occurs!
Input
Expected Output
Cheers
Solved! Go to Solution.
Try the RegEx tool with Output Method = Tokenize
Regular Expression = (.*?Question)
Chris
Hello,
Many questions around this to give you the right answer. Questions like, is it always 3 questions? is it always the word Question? etc
To answer your specific question with your specific example.
@ChrisTX has given you the tool to use. I would say the regular expression is something like
\d+.\d+\s*[[:alpha:]]+
The above looks for one or more digits, separated by a dot, followed by one or more digits etc.
I used alpha for any letter, you can use other. this is more generic
I hope this helps.
In addition to the great suggestions by both @ChrisTX @and@ImadZidan, another question that came to mind was a situation where you might have more questions for a given entity. For example, 4 questions for Entity 1, 5 for Entity 2, etc. I took ChrisTX's workflow, and added a bit to it to account for situations like this. The main change is a "Split to Rows" in the same RegEx tool, and some formulas to create some formatted column names, and then finally a CrossTab to pivot the table back into shape.