Hi, El 06/09/10 14:58, Thomas Mueller escribió: > Sorry, I see the SQL standard uses the term UNKNOWN. I didn't know > that. H2 doesn't support the keyword UNKNOWN currently, and in the > documentation the term UNKNOWN is currently never used. Instead, NULL > is used. To simplify things, I would like to not use the term UNKNOWN > except for compatibility. In an old book D.Chanberlain (SQL creator) use a full section to explaining he's controversial choice of include NULL values in SQL. There he clearly stated that NULL is a data type with only one value named NULL. NULL is NOT equal to nothing because the null value is an irregularity in any other data type that only express or mean the absence of a known value. Then NULL value/type is evaluated with the " IS [NOT] NULL " grammar in place of be compared with " = NULL ".
UNKNOWN is a descriptive term used for a NULL value in the evaluation of a expression of boolean type. So, in sql the boolean data type have only two values TRUE and FALSE OR don't have any value at all. In any context where a expression must to be evaluated for a boolean result ( for example in a where clause) if any operand is null then the expresion value is UNKNOWN having no effect in their context. > In my view, NULL should count as a value, it should be distinct and > smaller than any other value (also smaller than -infinity). However, > my view doesn't really count. What counts is compatibility with other > databases. NULL isn't comparable , but every implementation has the choice (or setup) of an ordering convention for null values as FIRST or LAST values. regards, Dario. -- You received this message because you are subscribed to the Google Groups "H2 Database" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/h2-database?hl=en.
