Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

How to remove all character after first 8 digits in a column

aishwarya_baburaj98
6 - Meteoroid

Hi All,

If below is an example for invoice# column, I want to remove any characters (this could be letters, special characters, and/or numbers). How can I remove the additional characters after first 8 numbers? Inputs and outputs are in excel formats

 

INVOICE NO
11111111
31111111
11111114\
11111111a.
11111111B
111111112
6 REPLIES 6
Pravallika20
8 - Asteroid

hi @aishwarya_baburaj98 

can u pls share the sample input and output files

atcodedog05
22 - Nova
22 - Nova

Hi @aishwarya_baburaj98 

 

Here is how you can do it. You can use regex_replace or Left

Workflow:

atcodedog05_0-1632223459018.png

OR

atcodedog05_1-1632223474823.png

 

Hope this helps : )

Pravallika20
8 - Asteroid

Hi @aishwarya_baburaj98 ,

 

Pravallika20_0-1632223482288.png

 

Hope this helps

Christina_H
14 - Magnetar

A couple of easy options would be to change the field length to 8 with a Select tool, or use a formula: Left([INVOICE NO],8)

Christina_Hurrell_0-1632223609326.png

 

pdave87
11 - Bolide

Hi,

 

There are many ways to parse data and in this use case I will suggest use functions - Left or Right to divide the data as required. Please refer below screen-print as solution. Refer rows from 3 to 6, hope this answers your question.

 

pdave87_0-1632223839695.png

 

Regards,

Pratik

 

pdave87
11 - Bolide

@Christina_H marvelous 🙂 simple yet out of the box. Good one! thanks.

Labels