diff --git a/content/feed/sas-special-missings/index.md b/content/feed/sas-special-missings/index.md index dbc9ee4..428f066 100644 --- a/content/feed/sas-special-missings/index.md +++ b/content/feed/sas-special-missings/index.md @@ -45,10 +45,10 @@ Once in SAS they are ordinary values, so they are what the approval DIFF screen These are Data Controller's own rules, configured per column in the `MPE_VALIDATIONS` table and applied in the browser as you edit and submit. -- `NOTNULL` - fails. A special missing is NULL as far as a NOT NULL (or primary key) constraint is concerned, so the rule rejects it - and so does a physical SAS NOT NULL constraint on the target table +- `NOTNULL` - works the same as SAS: cannot use special missings. A special missing is NULL to a NOT NULL (or primary key) constraint, so the rule rejects it, and so does a physical constraint on the target table - `HARDREGEX` - checked against the pattern like any other value; unlike blanks and the plain `.`, special missings are **not** exempt, so a numeric column that carries them needs a pattern which allows for a single letter - `SOFTREGEX` - the same check, but a failure is only a warning rather than a block, and it is ignored entirely if the column also has a `HARDREGEX` rule -- `SOFTSELECT` - never blocks, so a special missing passes; `HARDSELECT` is a strict membership test and rejects one +- `SOFTSELECT` - never blocks, so a special missing passes; `HARDSELECT` is a strict membership test, so it passes only when the dropdown list contains it - `ROUND` - harmless. It only rounds values that are numbers, so a special missing is left exactly as it was typed Special missings are **not supported** in a column that carries a range rule or a formula: @@ -93,10 +93,10 @@ We solved that in the open source SASjs Adapter, and it has been in Data Control How they behave in Data Controller's validation rules: -- NOTNULL fails - a special missing is null to a NOT NULL (or primary key) constraint, and a real SAS NOT NULL constraint rejects it too +- NOTNULL works the same as SAS - no special missings: one is null to a NOT NULL (or primary key) constraint - HARDREGEX checks it against the pattern, unlike blanks and plain . - SOFTREGEX warns instead of blocking (and is ignored if the column also has a HARDREGEX) -- SOFTSELECT lets it through; HARDSELECT rejects it +- SOFTSELECT lets it through; HARDSELECT only when the dropdown list contains it - ROUND leaves it alone, because it only rounds numbers Special missings are not supported where a range rule or a formula is configured: