Creating New Ids Using Combination Lookup Step In PDI

In database relationalship modeling , a unique key is a set of zero, one, or more attributes. The value(s) of these attributes are required to be unique for each tuple (row) in a relation. The value, or combination of values, of unique key attributes for any tuple should not be repeated for any other tuple in that relation.

When more than one column is combined to form a unique key, their combined value is used to access each row and maintain uniqueness. These keys are referred to as aggregate. or compound keys. Values are not combined, they are compared using their data types.

When a column or set of columns is defined as unique to the database management system, the system verifies that each set of value(s) is unique before assigning the constraint

This blog is about creation of unique ids for specific columns using Pentaho Data Integration.

We have taken a Text File Input step with certain values.Our goal is to create ids for each of these values.

We added a combination lookup/update step to generate ids for the same wherein we used the technical key as id and set it to the option of use Table maximum +1. This will automatically generate ids incremented by 1 and thereby maintaining uniqueness.Also we took the Dimension field and the Stream field as Territory.

Finally when we preview the output we can see ids being generated maintaining uniqueness.

You must be logged in to post a comment.