Feature request: regular expression support in expressions

There is currently no way to validate a text pattern with a regular
expression. A simple rule such as “this field must contain digits only” has to
be built as a chain of nested SUBSTITUTE() calls that strip each digit and then
check ISBLANK().

For a phone number field this produced a twelve-line expression that is hard to
read and easy to get wrong. We shipped one version that was missing a single
digit from the chain, which silently rejected valid input — the mistake was
only found by chance during a review.

What a REGEXMATCH-style function would replace:

AND(
ISBLANK(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(
SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(
[Phone], “0”,“”),“1”,“”),“2”,“”),“3”,“”),“4”,“”),
“5”,“”),“6”,“”),“7”,“”),“8”,“”),“9”,“”)),

)

with something like:

REGEXMATCH([Phone], “^[0-9]+$”)

The same limitation shows up for postal codes, IBANs, national ID numbers and
any other field with a defined format. A single function would remove a whole
class of hand-written, error-prone expressions.

This has been requested many, many times in the past. I hope someone acts on it this time (attn @cschalk_ws)!