Re: Sheer logical inconsistencies (of optimizer??)
Posted in 2006
Ulrich Mueller wrote: >>>that way it would still conform to >>>mathematical relation properties with NULL values, >> >>Please explain? >> > > > relation ~R on set M is a subset A of MxM, > we write x ~R y iff (x,y) is element of A, > > as I suppose, x ~R NULL is never true, > > but there IS a difference between SQL interpretation > > NOT (age>=21) > and > (age<21) OR age IS NULL > > (I just checked with mysql, the same problem, > so this is not really Informix topic, excuse me please, > but comments still welcome) Yes, according to the SQL standard and any properly compliant RDBMS, NULL compares FALSE to ANY value in a relational comparison (ie <, >, <=, >=, etc.) and inversely it compares FALSE in any NOT comparison also. Art S. Kagel