Join from another dataset
Function and purpose of the operation¶
The Join from another dataset operation allows you to define one or several fields of a target dataset based on values present in a source dataset or calculated values. However, it does not run checks on any row duplication at the end of the operation. Thus, the number of rows produced varies depending on the indicated conditions.
Matching fields are mandatory because you must specify at least one condition column and one attribute column to enable the update.
Note: If both source and target have a null value for a column used as a condition, the system treats them as two different rows. Therefore, the condition is not satisfied.
Advanced Tab¶
The source scenario /period fields allow you to define a scenario/period from which to read data for the given source dataset. It is possible to specify a value using the AW parameters or through the same syntax used in the definition of cell fields.
When the field is left blank, the DTP launch scenario/period is taken into account; however, in the case of a non-existent or inactive scenario/period, the DTP will go ahead without running the operation, reporting the failed execution in the audit.
Note: the advanced tab is only visible for physical or virtual datasets.
Example
Target Dataset¶
| CONTRACT | CUSTOMER | AMOUNT | COUNTRY | RATE |
|---|---|---|---|---|
| C2 | Madison White | 5000 | Rome | |
| C1 | Joe Black | 10000 | New York |
Source Dataset¶
| COUNTRY | RATE |
|---|---|
| Rome | 1.7 |
| Rome | 2.3 |
| New York | 1.5 |
In matching fields, the field to be used as a condition and the field to be used as an attribute are specified.
Matching fields¶
| Target field | Source field | Relationship type |
|---|---|---|
| COUNTRY | COUNTRY | Condition |
| RATE | RATE | Attribute |
After performing the Join operation from another dataset , the resulting dataset will be as follows:
Target Dataset¶
| CONTRACT | CUSTOMER | AMOUNT | COUNTRY | RATE |
|---|---|---|---|---|
| C2 | Madison White | 5000 | Rome | 1.7 |
| C2 | Madison White | 5000 | Rome | 2.3 |
| C1 | Joe Black | 10000 | New York | 1.5 |