Subject RE: [firebird-support] Re: Possible to write this in a way that indices will be used
Author Maya Opperman
>Doru wrote:>
>If you are using Firebird 2+ Testing DISTINCTness will be a nice way
>to go :
>http://www.firebirdsql.org/manual/nullguide-langelem.html

OK, so ((D.SuplCde = :ISupplierCode) or (:ISupplierCode is null))

would change to ((D.SuplCde is not distinct from :ISupplierCode))

to achieve the same results?

Ie. if D.SuplCde is 'ABC' and ISupplierCode is 'ABC', result will be
TRUE.
if D.SuplCde is 'ABC' and ISupplierCode is NULL, result will be
TRUE??
if D.SuplCde is 'ABC' and ISupplierCode is 'XYZ', result will be
FALSE.

Is that right?

Thanks
Maya