docs(config): derived variables in the EDIT screen #21
@@ -54,11 +54,11 @@ ACTIVE 1
|
|||||||
For each row, Data Controller generates the following statements when the table is read:
|
For each row, Data Controller generates the following statements when the table is read:
|
||||||
|
|
||||||
```sas
|
```sas
|
||||||
attrib REGION length=$8 label='DERIVED: ifc(STATE in (''CA'',''OR'',''WA''),''West'',''East'')' format=$8.;
|
attrib REGION length=$8 label='REGION=ifc(STATE in (''CA'',''OR'',''WA''),''West'',''East'')' format=$8.;
|
||||||
REGION = ifc(STATE in ('CA','OR','WA'),'West','East');
|
REGION = ifc(STATE in ('CA','OR','WA'),'West','East');
|
||||||
```
|
```
|
||||||
|
|
||||||
The label defaults to the expression itself, prefixed with `DERIVED: `, so that computed columns are obvious when labels are switched on. The expression is truncated to the maximum label length.
|
The label is the variable name, an equals sign and the expression - `REGION=ifc(...)` - so the column shows both what it is and where it comes from when labels are switched on. The expression is truncated to the maximum label length.
|
||||||
|
|
||||||
The type and length are declared, not inferred, so a value is truncated exactly as you specify. If `VAR_FMT` is left blank, character variables default to `$<length>.` and numeric variables to `<length>.`; a date, time or datetime format makes the column render (and filter) as a date, time or datetime, the same way a stored column does.
|
The type and length are declared, not inferred, so a value is truncated exactly as you specify. If `VAR_FMT` is left blank, character variables default to `$<length>.` and numeric variables to `<length>.`; a date, time or datetime format makes the column render (and filter) as a date, time or datetime, the same way a stored column does.
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user