Subject Re: [firebird-support] Strange SIMILAR TO result
Author Dimitry Sibiryakov
07.05.2018 12:19, Gabor Boros mlnglsts@... [firebird-support] wrote:
> A simple example: SELECT ''='' SIMILAR TO '[A-Z]{2}[0-9A-Z]{2,13}' FROM
> RDB$DATABASE
>
> Why is the result true?

Your expression is actually calculated as "CAST(''='' as CHAR(5)) SIMILAR TO
'[A-Z]{2}[0-9A-Z]{2,13}'".
(''='') is true and string representation of true is 'TRUE ' that matches your patters.


--
WBR, SD.