I have a column with 5 digits, 6 digits, 10 digits and 9 digits value.
I only need to filter the value with 5 & 6 digits.
I tried RegEx ribbon but if I say 5,6 in a column it trims of other values as well. I don't need that to happen.
Any help will be very helpful....
Thanks,
Solved! Go to Solution.
I'm not sure I follow exactly, but if you are wanting to keep only strings that are 5 or 6 digits long, you can filter with this formula:
REGEX_Match(ToString([Strings]), '^\d{5,6}$')
This result for TRUE node:
This for FALSE node:
Hi @vpalani08
Here's a non-regex approach. Depending on if your data is a string or numeric the 'tostring' piece may not be necessary.
Length(tostring([Field1])) in (5,6)
Thanks that works perfectly.
Thank you for this solution I like it, however lets say if i want to filter the data that has 1,2,3,4 numbers in it like
1
11
111
1111
I tried using the formula and by adding additional required values but it didn't work as its only working for 2 values
REGEX_Match(ToString([ACCT-NBR]), '^\d{1,2,3,4}$')
Did i do anything wrong in the formula ??
Change it to the below and it should work
REGEX_Match(ToString([ACCT-NBR]), '^\d{1,4}$')
Hi @Luke_C Thanks for your reply, yup works like a champ :)