You are not logged in.
Announcement
Unanswered posts
|
Pages: 1
eno;role;dept
1;App;10
1;Cert;10
1;App;20
2;App;10
2;Cert;10
2;Rev;20
2;Cert;30
3;cert;10
how to use tIterate and TMap to do get the output like this
eno;app_flag;cert_flag;rev_flag
1;y;y;n
2;y;y;y
3;n;y;n
Hi,
No need for tIterate:
tFileInput --> tMap --> tAggregateRow --> (rest of job)
Send the input to a tmap with eno;app_flag;cert_flag;rev_flag
map row1.eno to output.eno
"App".equals(row1.role)?"y":"n" mapped to app_flag
"Cert".equals(row1.role)?"y":"n" mapped to cert_flag
"Rev".equals(row1.role)?"y":"n" mapped to rev_flag
send this to a tAggregate row
group by eno
max() each of the other fields
Thanks,
Ben
Offline
Pages: 1