Free Trial

Alteryx Designer Desktop Discussions

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

Tagging company names that have 6 digits at the end of the name

Radeg111
5 - Atom

Hi All. I am trying to get Alteryx to perform what is basically an Excel function. I regularly process Excel reports where I have to tag all customer names that have 6digits at the end of their name. Does anyone have an idea on how to do this in Alteryx workflow?

In Excel, I am able to achieve this by using function

"=AND(ISNUMBER(VALUE(MID(A3, LEN(A3)-5,1))),ISNUMBER(VALUE(MID(A3, LEN(A3)-4,1))),ISNUMBER(VALUE(MID(A3, LEN(A3)-3,1))),ISNUMBER(VALUE(MID(A3, LEN(A3)-2,1))),ISNUMBER(VALUE(MID(A3, LEN(A3)-1,1))),ISNUMBER(VALUE(MID(A3, LEN(A3),1))))"

 

Example below

 

Capture1.JPG

3 REPLIES 3
SPetrie
13 - Pulsar

Im sure there is a better formula, but using REGEX_Match([Client Name],".+\d{6}") should work

pic.PNG

cjaneczko
13 - Pulsar

You can use the following

 

If REGEX_Match([CLIENT NAME], '.*\d{6}$') then 'Y' else 'N' endif
TUSHAR050392
11 - Bolide

I can help you here. I would use a formula tool after the input and you can create a new column which will contain the formula - right(Client Name, 6). After this we will use the Regex tool and in that we will select the new column created. In the Regular expression, you will type in (\d{6}) and then select output method Match. Wherever there will 6 digits, it will show as True in the new matched field created by Regex and then you can Tag True rows as Y and other as N using a formula tool.

 

Hope this help. Please mark it as a solution if it does.

Labels
Top Solution Authors