We have extended our Early Bird Tickets for Inspire 2023! Discounted pricing goes until February 24th. Save your spot!

Alteryx Designer Discussions

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

Working with non Ascii character

Carlithian
8 - Asteroid

So I have some data that I would like to parse but hitting some issues. So for example I have this string

 

<div class=""tags""> 萓区枚・廱LPT N5 Tango </div> 

 

If I use a replace formula on it like this below, you can see it doesn't change anything

Carlithian_0-1666726608766.png

 

But if I only use ascii characters it works as expected

Carlithian_1-1666726647186.png

Is there some setting I have to change in Alteryx to allow me to use the Kanji etc in expression? I have switched the language of designer to Japanese and that got me nowhere.

5 REPLIES 5
binuacs
17 - Castor

@Carlithian Do you want to remove the non-ASCII letters?

 

binuacs_0-1666727566165.png

 

Carlithian
8 - Asteroid

I'm actually wanting to keep them, but continuing to play in designer I realised I made a silly mistake and it worked fine -.-
Thats a really useful formula, is there a reverse for getting rid of all ascii characters?

binuacs
17 - Castor

@Carlithian removing the ^ sing from the Regex_Formula will give you the non-ascii characters

 

binuacs_0-1666734308469.png

 

flying008
12 - Quasar

Hi, @binuacs 

 

Dear, your regex expression is so cool , but could you please tell me that where are the [ -~] syntax from?

binuacs
17 - Castor

@flying008 [ -~]

 

[ -~] uses (space) followed by a dash followed by a tilde. This regex expression includes all the characters between space and tilde. If you see the below chart any character from 32 to 126 is replaced with '' as per the below regex formula and the rest of the characters will remain

REGEX_Replace([Field1], "[ -~]", '')

 

binuacs_0-1666852741754.png

 

Labels