Subject | Re: [ib-support] Auditing updates |
---|---|
Author | Nando Dessena |
Post date | 2002-02-12T09:55:24Z |
Set,
I have once been told that your table should be corrected this way:
= null))) should be true, which is not the case as this is not boolean
algebra. I think a simple test can be made:
if (null = null) then
A
else
B
This should return B.
if (not (null = null)) then
A
else
B
This should return B as well.
I am far from being sure of this since I avoid comparing nullables in
the first place, but I would be glad if anyone could confirm or correct
that.
Ciao
--
____
_/\/ando
> No, it wouldn't. Comparisons with NULL evaluates as follows:so it shouldn't match false as well as it doesn't match true. :-)
>
> NULL = 1 false
> NULL = NULL false
> NULL <> 1 false
> NULL <> NULL false
>
> NULL is a state meaning that you don't know and doesn't match anything.
I have once been told that your table should be corrected this way:
> NULL = 1 nullif (null = null) were false, then (null <> null) (or, better, (not(null
> NULL = NULL null
> NULL <> 1 null
> NULL <> NULL null
= null))) should be true, which is not the case as this is not boolean
algebra. I think a simple test can be made:
if (null = null) then
A
else
B
This should return B.
if (not (null = null)) then
A
else
B
This should return B as well.
I am far from being sure of this since I avoid comparing nullables in
the first place, but I would be glad if anyone could confirm or correct
that.
Ciao
--
____
_/\/ando