This is the scenario faced by a candidate when he had repeated values in his SQL Server records as shown in the image down below.
If we try to run the package it will throw us an error,
The error says that the pivot key has a duplicate value.
To solve this error we will add a new component on our SSIS package available from SSIS toolbox under transformationknown as Aggregation Transformation. With the use of this component duplicate values will be removedand it will become one while Sales Amount gets aggregated.
This new Aggregate component is asked by candidate of MSBI training to place it between “OLE DB Source” and “Sort” component.
To remove redcross mark seen over “Aggregate” component even after connecting data path to each component. Double click and open its editor window to configure it.
After Editor window is open set “SalesAmount” operation field to “Sum” as shown in the image down below.
After configuring the Aggregate transformation, we then execute the package,
The output shown below is from the laptop of MSBI training candidate where duplicate values for “Jan” and “Sun” has their “Sales Amount” field aggregated.