Re: Bug in SQLite version 3.31.1 and 3.32?

Joe Mucchiello <jmucchiello-/[email protected]> Sat, 7 Mar 2020 16:35:37 +0000 (UTC)
Newsgroups gmane.comp.db.sqlite.general
Message-ID <[email protected]>
 I just want to point something out that might help the original poster.

    On Saturday, March 7, 2020, 7:00:21 AM EST, [email protected] <[email protected]> wrote:  > 
> 1.  NULL is NULL = Yes, True,
> 2.  NULL is FALSE = Nope, False.
> 3.  NULL is TRUE  = Nope, False.
> 4.  NULL is NOT NULL = Nope, False,
> 5.  NULL is NOT FALSE = Yep, True.
> 6.  NULL is NOT TRUE = Yep, True.
> 7. TRUE is FALSE  = Nope, False.
> 8. TRUE is NOT FALSE = Yep, True.
> 9. FALSE is NOT TRUE = Yep, True.
This explanation 100% correct and probably 80% confusing without the following, especially because "is" is not capitalized:IS and IS NOT are logical operators in SQL. NOT is not a unary operator when preceded by IS.

In most non-relational languages "NULL IS NOT TRUE" is parsed as:

value(NULL) operator(IS) (operator(NOT) value(TRUE)). 

That is NOT how SQL works. In SQL, it is:

value(NULL) operator(IS NOT) value(TRUE).


  
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users