Variable (DB)
Use to define variables created from data fields of the input data set, forming a new table or view.
Information at a Glance
The Variable operator also allows users to divide the data rows into quantiles, adding quantile variables to the data. Dividing the data into such smaller and smaller divisions (quantiles) provides an understanding of the overall data distribution patterns.
Configuration
Parameter | Description |
---|---|
Notes | Any notes or helpful information about this operator's parameter settings. When you enter content in the Notes field, a yellow asterisk is displayed on the operator. |
Variables | Define the expression(s) to create the new Variable column(s).
For details, see Define Variables dialog box. |
Quantile Variables | If the new variable to create is a quantile variable, select the required column(s) to use for deriving the quantiles.
The possible quantile types are Average Ascend (which automatically creates the bins) and Customize (which manually defines the variable bins). Note: Automated variable binning can run on only databases that support NTILE, such as Greenplum, Postgres, Oracle, and SQL Server. It is not supported on databases such as Teradata, MySQL, and MariaDB that do not currently support NTILE.
See Define Quantile Variables dialog box for more information. |
Columns | See Select Columns dialog box. |
Output Type | |
Output Schema | The schema for the output table or view. |
Output Table | The table path and name where the results are output. By default, this is a unique table name based on your user ID, workflow ID, and operator. |
Storage Parameters | Advanced database settings for the operator output. Available only for
TABLE output.
See Storage Parameters Dialog Box for more information. |
Drop If Exists | Specifies whether to overwrite an existing table. |
Output
- Visual Output
- The data rows of the output table or view displayed. The new Variable columns, such as
morethan3k in the example below, are displayed.
To see all of the data rows in addition to the derived variables, select all columns for the Columns parameter.
- Data Output
- A data set of the newly created table or view.
Additional Notes
The Variable operator also provides the following useful functions.
- Parses data fields stored in a key-value pair format, such as JSON, dictionaries, and database STRUCT formats. For details, see Key-Value Pairs Parsing Example using the Variable Operator.
- Converts datetime formats. For details, see datetime Format Conversion Examples.