MATCHES

MATCHES

Syntax

MATCHES(<string>,<string with regular expression>)

Description

Returns a boolean value (true or false) depending on whether a string matches a regular expression. Datameer tries to match entire record without automatically adding or $ to the regular expression. But if the record has multiple lines, then this must be accounted for with (?s) or line terminatorsThe each cell must have a value and can't contain a <null> value. Update columns containing <null> values using functions like DENULLIFY or ISNULL.

Examples

Column1

Column2

MATCHES returns

Column1

Column2

MATCHES returns

nonemptylowercase

.[a-z]*

true

nonemptylowercase

.[A-Z]*

false

,

.[A-Z]*

false

=MATCHES("nonemptylowercase", ".[a-z]*") returns boolean value true =MATCHES("nonemptylowercase", ".[A-Z]*") returns boolean value false =MATCHES("", ".[A-Z]*") returns boolean value false