So if NULL is not defined, what's the difference between "is NULL" and "=NULL". I guess my disagreement comes from not being able to ask for undefined field by =undefined, but rather is undefined. It's all a matter of syntax and I doubt there is a theoretical explanation for this in SQL, or maybe there are lots:-). Though the way that DB vendors implement their SQL engines prevents (in many cases) in easily reusing the query using placeholders, of course there are many ways around. This is getting OT, unless it will in some ways spark any ideas for DBI/DBD patches.
Ilya -----Original Message----- From: Bud Rogers To: [EMAIL PROTECTED] Sent: 10/23/01 4:07 PM Subject: Re: = NULL vs. IS NULL On Tuesday 23 October 2001 16:56 pm, Bart Lateur wrote: > On Tue, 23 Oct 2001 12:35:57 -0500, Stephen Clouse wrote: > > >This is not Oracle, but ANSI-standard behavior. NULL represents the absence or > >non-existence of a value. A non-existent value cannot be equal to anything. So > >this is the correct behavior. I personally don't think DBI should muck with > >proper behavior. > > My personal opinion is to disagree. To me, NULL means "empty". It is not > the same as a zero length string. But empty is empty, thus NULL=NULL. > > Nitpicking that NULL != NULL, is only making our life harder. > > Last week, there was a similar discussion going on, on the Perl6 mailing > lists, with regards to NaN (Not A Number). Is NaN==Nan, or NaN!=NaN? Bruce Momjian spends a couple of paragraphs in the elephant book explaining why NULL doesn't equal anything, including NULL. NULL is not NaN, NULL is undefined. -- Bud Rogers <[EMAIL PROTECTED]> They have awakened a sleeping giant and filled him with a terrible resolve.