i am having a problem with case sensitive regex in my smart rules. this is the rule:
Scan text - regex - IE([0-9A-Z]*).
i would have expected to match on
IE00BK5BQT80 but it matches on
Wien instead. it should neither match on
ie nor on the
n since it isn’t in the regex.
Content is literally just
Wien is a test
what am i doing wrong here? How could i enforce case sensitivity? Thanks a bunch.
You can use
(?i) at the beginning for case-insensitive matches but I think there’s a bug here.
@BLUEFROG it seems to be case insensitive already.
(-?)IE([0-9A-Z]*) does not match
That’s correct and intentional (and consistent to searching in databases).
had a typo above
(?-i) works it seems.
not sure i agree with you as with a regex you can very explicitely search for things.
We might add an option to future releases.
May I suggest to simply stick to what is common practice with REs? I.e. respect case-sensitivity unless the i flag is specified. Everything else is… unexpected. Although database search is case-insensitive, it does not permit REs anyway, so one does not really need alignment in this respect. My opinion, of course.