REVERSE_NORMALIZE
Reverses the normalization transformation on normalized data, thereby de-normalizing the normalized data. If normalized data is used as the input, the original data is returned. If you specify a column that is not in the specified model, REVERSE_NORMALIZE returns that column unchanged.
Important: Before using a machine learning function, be aware that all the ongoing transactions might be committed.
Syntax
REVERSE_NORMALIZE ( col1, col2 ..., coln USING PARAMETERS model_name='model_name');
Arguments
col1, col2 ..., coln |
The columns to use from the input table or view. |
Parameters
model_name |
The name of the model. Model names are case-insensitive. Value must be VARCHAR. |
Privileges
To use REVERSE_NORMALIZE, you must either be the dbadmin, owner of the model or have USAGE privileges. There are no privileges needed on the function itself.
See GRANT (Schema) and GRANT (Table).
Examples
This example shows how you can use the REVERSE_NORMALIZE function on the hp
and cyl
columns in the mtcars table, where hp
is in the normalization model and cyl
is not in the normalization model.
=> SELECT REVERSE_NORMALIZE (hp, cyl USING PARAMETERS model_name = 'mtcars_normfit') FROM mtcars; hp | cyl ------+----- 42502 | 8 58067 | 8 26371 | 4 42502 | 8 31182 | 6 32031 | 4 26937 | 4 34861 | 6 34861 | 6 50992 | 8 50992 | 8 49577 | 8 25805 | 4 18447 | 4 29767 | 6 65142 | 8 69387 | 8 14768 | 4 49577 | 8 60897 | 8 94857 | 8 31182 | 6 31182 | 6 30899 | 4 69387 | 8 49577 | 6 18730 | 4 18730 | 4 74764 | 8 17598 | 4 50992 | 8 27503 | 4
(32 rows)