4 ms·
The problem, though, is that SQL standard treats NULL as unknown or as missing. One word for two meanings. For example, AVG(col) and COUNT(col) treat it as a m
by FedericoRazzoli 5y ago
The problem, though, is that SQL standard treats NULL as unknown or as missing. One word for two meanings.
For example, AVG(col) and COUNT(col) treat it as a missing value (NULLs do not alter the average or the count), but 1 + NULL treats it as an unknown value (the result is unknown). The complete list of NULL-related inconsistencies would be long.
It would have been better to use different words for different semantics, or not implementing NULL at all. Also, in some cases it can lead to poor query performance.
- civilized 5y agoI emphatically reject the idea that having an imperfect null is worse than no null at all, but I understand frustrated programmers may have different beliefs.