Alteryx Designer Desktop Discussions

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

Select numbers within text

datwell25
5 - Atom

Apologies if this has been asked before....I cant seem to find what I am after.

 

I have a field where I want to select only 4 digits from text which is in the middle of the data. What formula/expression do I use for this?

 

Sample:  L300033010101  (I need the numbers from 6-9, therefore L300033010101 )

 

Expected result: 3301

 

Many thanks.

 

 

2 REPLIES 2
BenMoss
ACE Emeritus
ACE Emeritus

Check out the substring() function within the formula tool.

 

In your instance something like 

 

substring([field],6,4)

Should do the trick.

 

Ben

datwell25
5 - Atom

Thanks Ben......worked a treat. 

 

Much appreciated.

Labels