It's pronounced Diane. I do data architecture, operations, and backend development. In my spare time I maintain Massive.js, a data mapper for Node.js and PostgreSQL.
Boolean logic is built around the binary values TRUE and FALSE. SQL, however, is built around a three-valued logic: TRUE, FALSE, and NULL, where the last is an unknown or undefined value. For more detail you could consult Wikipedia or appendix D in de Haan and Koppelaars' Applied Mathematics for Database Professionals, but the short version is that NULL cannot be compared to a known value: any comparison with an unknown value yields an unknowable result.
Postgres has a shortcut: x IS [NOT] DISTINCT FROM y, although that's likely not much help here with a list of values.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Boolean logic is built around the binary values
TRUE
andFALSE
. SQL, however, is built around a three-valued logic:TRUE
,FALSE
, andNULL
, where the last is an unknown or undefined value. For more detail you could consult Wikipedia or appendix D in de Haan and Koppelaars' Applied Mathematics for Database Professionals, but the short version is thatNULL
cannot be compared to a known value: any comparison with an unknown value yields an unknowable result.Postgres has a shortcut:
x IS [NOT] DISTINCT FROM y
, although that's likely not much help here with a list of values.