You are not logged in.
Announcement
Unanswered posts
|
Pages: 1

Hello Talend Team,
I have list of csv file which contain transaction details and I want to find distinct accountid from all of them for second subjob.
for example my csv file contain data like
Tractionfile 1
AccountId TranctionId BalanceAmt
1 112 100.00
2 201 100.00
4 113 200.00
1 114 400.00
Tractionfile 2
AccountId TranctionId BalanceAmt
2 202 200.00
3 564 800.00
1 205 555.00
I want to store only distinct AccountId separated by comma in context variable to use in another subjob.
like
context.variable = "1,2,4,3";
my job desing
tfileList-------iterate---->tFileInputeDelimeter---------->tMap-----tLogRow------>[2nd subJob]
(want to calcualte context.variable (want to use context.variable value here)
value here )
Please suggest me how to find distinct account id and store it in context variable.
Thank you,
Nitin
Last edited by NitinMunjani (2012-06-15 08:28:51)
Offline
Try tAggregateRow and normalize the output.

Hi dentiston
can you please explain me how do I get my output through tAggregateRow and tnormalize.
Offline

Hi
Try this:
tFileList [iterate]-> tFileInputDelimited -> tUnite -> tFilterColumns -> tDenormalize -> Output
The tUnite unites the iterations into a single flow (much like writing all of the inputs to a single interim file, then reading the interim file again).
Make sure the tDenormalize has "Merge same value" checked - this will get rid of duplicate account ids.
JB
Last edited by jonathanbowen (2012-07-16 17:59:01)
Offline
Pages: 1