The Add Constant String Processor adds a new column to an existing dataset containing constant string values.
In other words, it adds a column that contains the same specified string in every row.
The processor works with any valid dataset.
The initial dataset with one additional new column filled with the specified value.
In this example, we take a sample dataset with station data (attached at the bottom of the article) and split it in half. Then we put it back together, but we want to make sure to keep the information what data point belonged to which half.
This is a small snippet of the input data table:
In this workflow, we load the sample data table with a Data Table Load Processor, then split it in half with the Horizontal Split Processor. To each part of the dataset we add a new column that indicates to which half the data points belong by adding a constant string. In the end, we unite it again with a Union Processor.
This is the configuration of the two Add Constant String Processors.
As a result, we get the united dataset with the new column at the end. This is a snippet of it: