ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests Early 2026. Make sure to check your account preferences in my.alteryx.com to make sure you have filled out your security questions. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
解決済み

Filtering out values that contain anything but a number

wht822
メテオール

Hello,

 

One column in my dataset contains multiple different types of data (addresses, dates, numbers, etc...). and I want to filter out anything that contains a non-numeric value. This way, titles and dates are all done away with and I'm only left with columns that are only a numeric value. I feel like this could be a simple solution, but I'm having difficutly coming up with it. Does anyone have any ideas?

 

 

Thanks!

4件の返信4
MarqueeCrew
20 - Arcturus
20 - Arcturus

Filter using:

 

regex_countmatches([field],"\D") > 0

 

 cheers,

 

 mark

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
wht822
メテオール

Looks like that filtered out everything but whole numbers. Any idea how I could keep non-whole numbers as well?

MarqueeCrew
20 - Arcturus
20 - Arcturus

This version allows for {0-9,commas,decimal points}

 

Filter using:

 

regex_countmatches([field],"[^\d,\.]") > 0

 

 cheers,

 

 mark

Alteryx ACE & Top Community Contributor

Chaos reigns within. Repent, reflect and restart. Order shall return.
Please Subscribe to my youTube channel.
rdeeparnell
アトム

do I still need to change the data type of the field that I am filtering?  I keep getting the following error: Formula:tried to apply string operator to numeric value

ラベル
トップのソリューション投稿者