Most of you know that Informatica does not provide a function for denormalization. However, denormalizing a table is easy and could be done in Informatica by using two functions: an Expression and an Aggregator.
Let us look at the data:
Let us look at the desired output:
Let us look at the general architecture of the mapping:
Make sure that we sort the on CUSTOMER_ID asc. This is needed so we can send sorted input to the aggregator.
Let us look at the Expression function
The expression function will set the Brand to “Y” if it exists else it will set it to “N”.
Let us look the Aggregator function:
The final step is easy just connect the Aggregator to the Target:
If you are interested in a more complicated example please check: Denormalize Transactional Data using Informatica