Loading section...
Sentinel values and fake NULLs
Concepts: sqlNullif
Sentinel Values Many software systems are forced to produce values even when the data isn't known. This happens for several reasons: When a system must produce a value but doesn't know the real answer, developers choose "placeholder" values. These sentinel values become embedded in the data and persist for years. Common Sentinel Values These placeholders may seem harmless, but they complicate every query that touches the column. Practical Implications Consider why these patterns emerge in actual systems: Empty String vs NULL In practice, most systems don't track this distinction. Form submissions often send '' for unanswered questions, and databases store it as-is. The meaning of "unknown" gets lost. Detection and Handling When analyzing data, you must understand what placeholder values ex