Alteryx Designer Desktop Discussions

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

Need to split out the first 5 digits of a string into a new row

lb345
5 - Atom

Hi,

 

I am working on a workflow, and part of it, I need to split out a string, so I can separate out the first 5 digits into a new row. Thanks in advance! For example:

 

So I only want the first 5 digits of center to be split into a new row.

 

Input 
TypeValue
CENTER1111199999
CENTERName999TESTTESTTEST
  
  
Output 
TypeValue
CENTER1111199999
CENTERName999TESTTESTTEST
CENTERNEW11111
2 REPLIES 2
jdunkerley79
ACE Emeritus
ACE Emeritus

Something like this might work for you

2018-12-21_17-28-49.png

 

Use the filter to pick rows you need (just Center in example you gave)

Adjust the values with formula tools

Finally union back together with original data

jmstampe
8 - Asteroid

Maybe something along the lines of this may help?  I'm splitting out the CENTER from CENTERNAME using the filter tool then I create a new field that only looks at the first 5 characters of CENTER.  I then transpose that new field so the new field name becomes part of the row.  I change the newly transposed field to match the original input (Type) and then union the original to the updated.

 

Hopefully that all makes sense or helps out.

Labels