|
|
|
|
|
by daigoba66
1432 days ago
|
|
Coming from an MS SQL Server background, this behavior surprised me. While SQL Server generally does treat null values as not equal in query predicates, for the purpose of unique constraints/indexes it’ll treat them as the same value. I guess this does go against the spec? But it makes sense as a human when looking at a tuple and deciding if it is “unique” or not. On that note, now I wonder what SQL Server does with nulls in a DISTINCT or GROUP BY. I suspect that it’ll treat all nulls as the same. |
|
https://blog.sqlauthority.com/2015/02/13/sql-server-warning-...