On 25/11/2014 13:29, [email protected] [firebird-support] wrote:
select
iif('[email protected]' similar to
'([_a-zA-Z\d\-\.]+@[_a-zA-Z\d\-]+(\.[_a-zA-Z\d\-]+)+)','ok','fail')
from rdb$database
Says 'invalid string' and 'invalid pattern', but the pattern it´s the
same in other languages for validate email address.
Well, just a couple of general observations:
- there is no such thing as a regular expression that can validate an
email address, at best you can get an approximation that works "quite
often" but still gets it wrong sometimes
- there are dozens of languages all with slightly different rules for
regular expressions, it's not a surprise if any non-trivial regular
expression needs changing between languages, you just have to read the
rules for the new language.
--
Tim Ward