Subject Re: [firebird-support] Re: Problem with FB 2.0 and '=' operator
Author Ann W. Harrison
ainpoissee wrote:
> --- In firebird-support@yahoogroups.com, "William Gonzáles S."
> <wgonzaless@...> wrote:
>
>> But, if I execute this:
>> select * from CONTAINERS where NAME='Ventas'
>>
>> It gives and empty recordset, this happen in all SQL
>> queries with '=' operator.
>
> What's the type of NAME column? If it is CHAR(X) then there may be
> trailing spaces which make it to fail. VARCHAR() type should work.

There's something more subtle going on .... Firebird handles string
equality correctly. The standard states that when strings of unequal
length are compared, the shorter string is implicitly extended with
spaces.


Regards,


Ann