Alteryx Designer Desktop Discussions

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

Extract Number

Ar13f
10 - Fireball

Dear All,

 

I ask for your help for the problem below, I want to take only the numbers, namely :

 

"abcd 1 PqDTwYY - ZooTrY,(1013.686 Meters)" ------> 1013.686

 

and I've used regex : ".+\((\d.*)\)" and the result is 1013.686 Meters but I can't get rid of the word "Meters"

 

Regards,

Ar1ef

8 REPLIES 8
camie
6 - Meteoroid

@Ar13f

if you want to extract all numbers present in your field you can try this: REGEX_Replace([Field1],"[^0-9]","")
[Field1] = "abcd 1 PqDTwYY - ZooTrY,(1013.686 Meters)" 


or you can use regex tool

camie_0-1656748619435.png

 

 

camie_2-1656748669250.png

 

 

 

binuacs
20 - Arcturus

@Ar13f one of doing this with the Regex Tool

binuacs_0-1656748502972.png

 

Ar13f
10 - Fireball

Dear @camie 

 

thank you for your response .... I just want "1013.686" 

if I use your formula the result is "11013686"

binuacs
20 - Arcturus

@Ar13f Another way of dong this with the Regex_Replace function

 

REGEX_Replace([F1], '[^\d+\.]', '')

 

binuacs_1-1656748647526.png

 

camie
6 - Meteoroid

edited the reply above...

Ar13f
10 - Fireball

Dear @camie 

 

thank you ... solved

Ar13f
10 - Fireball

Dear @binuacs 

 

thank you for suggestion ... but I need just "1013.686"

 

 

 

Ar13f
10 - Fireball

I have a lot to learn in order to utilize RegEx because I find it difficult to use.

Labels