-
Notifications
You must be signed in to change notification settings - Fork 112
Open
Description
The section on persistent says:
The reason for this is that the SQL standard is ambiguous on how uniqueness should be applied to NULL (e.g., is NULL=NULL true or false?). Besides that ambiguity, most SQL engines in fact
implement rules which would be contrary to what the Haskell datatypes anticipate (e.g., PostgreSQL says that NULL=NULL is false, whereas Haskell says Nothing == Nothing is True).
My understanding had alway been that NULL=NULL gave NULL, and indeed in the Postgres on my machine at the moment (9.6.5) as well as the sqlite, select (null = null) is null evaluates to true. The article on SQL Nulls believes the distinction is worth calling out in its own section.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels