I have a requirement to generate the same set of records based on codes & input data.
my input data looks like
John|101|M|23
Kathy|102|F|40
Jean|103|M|23
Pauk|104|M|55
I have standard codes US,GB,MX,CA
and the output should be
John|101|M|23|US
John|101|M|23|GB
John|101|M|23|MX
John|101|M|23|CA
Kathy|102|F|40|US
Kathy|102|F|40|GM
Kathy|102|F|40|MX
Kathy|102|F|40|CA
Jean|103|M|23|US
Jean|103|M|23|GB
Jean|103|M|23|MX
Jean|103|M|23|CA
Paul|104|M|55|US
Paul|104|M|55|GB
Paul|104|M|55|MX
Paul|104|M|55|CA
Looping or Iteration based on codes
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Agreed, very easily accomplished using a Transformer looping through a list of state abbreviations with which you probably initialize a stage variable.
I assume the GM was a typo, that the list is the same for all input records. If not, some extra complexity needs to be introduced, but the task likely remains doable.
I assume the GM was a typo, that the list is the same for all input records. If not, some extra complexity needs to be introduced, but the task likely remains doable.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.