Subject Re: [firebird-support] Re: Why "Like" , "=" return diffent number records?
Author Helen Borrie
At 09:07 AM 8/10/2003 +0000, you wrote:
>Thanks to your help;
>I use sybase ASA,ASE,
>these 2 SQL statement("like","=")
>always return same Result(all 150 recordcount);
>Why doesn't FB act like Sybase?

Why would we want it to? Sybase is a very old dbms that predates the ISO

Firebird's implementation of LIKE is SQL-92 standard, which specifies a
pattern-matching search with wildcards. The standard wildcards are '%'
which represents "any characters in this position including no characters"
and '_' which represents "any single character in this position". The
standard says that blanks are significant in LIKE searches, so...

'AAA' like 'AAA ' is not a match, but 'AAA%' like 'AAA ' is a match.

You can ESCAPE the wildcard characters if you want to search for '%' or '_'
as characters in the pattern.