At 01:44 PM 8/3/00 +0000, Thomas Lockhart wrote:
>> Not compatible with the current release of MS SQL/MSDE :-) At least not
>> fully.
>
>The original issue was that "foo = NULL" is *not* a legal SQL92
>statement.
Ummm...I think this is wrong, and I have Date on my side (I just
checked). foo = NULL is NULL, just like foo + NULL is NULL.
If foo = NULL is illegal, doesn't this make it rather difficult to
say things like table1.i = table2.i for tables that contain NULLs
in column i?
Oracle allows it, and returns NULL. Oracle's fairly trustworthy
on low-level standards compliance over things like NULL (not
entirely, though - it treats '' as NULL in the VALUES list of
an INSERT, though not elsewhere, for instance).
NULL = NULL is also perfectly legal, returning NULL. Before one
gets too excited, NULL <> NULL and NULL < NULL etc all return
NULL, too, along with NULL = <anything> so it's not terribly
useful, which is why IS NULL exists.
- Don Baccus, Portland OR <dhogaza(at)pacifier(dot)com>
Nature photos, on-line guides, Pacific Northwest
Rare Bird Alert Service and other goodies at
http://donb.photo.net.
In response to
Responses
pgsql-hackers by date
| Next: | From: Tom Lane | Date: 2000-08-03 13:55:35 |
| Subject: Re: comparing rows |
| Previous: | From: Thomas Lockhart | Date: 2000-08-03 13:44:22 |
| Subject: Re: comparing rows |