Hi, my input is: date;type;name;value 2009-07-10;X;A;1.2 2009-07-10;X;B;2.1 2009-07-10;Y;A;3.1 2009-07-11;X;B;1.5 Output is expected: date;type;A;B 2009-07-10;X;1.2;2.1 2009-07-10;Y;3.1;null 2009-07-11;X;null;1.5 This transformation can easily be handled with tPivotOutputDelimited, but the performance is lousy (50.000 records take 30 minutes). I have then used tjavaRow to gather the counters per date/type-key in variables and write the output after all counters are gathered. This can be done after the date/type-key changes. In the case of my example it means that the first line 2009-07-10;X;1.2;2.1 will be written when the third input line is processed and the 2nd line 2009-07-10;Y;3.1;null willbe written when the fourth input line is processed. This works much faster than the pivot-function but one issue is still open: The last output line will never gets written since tjavaRow will not be called afterward. Hence I need an exit-routine to write out the stored values for last date/type-key. How can I carry out this task? Can I use tjavaFlex instead of tjavaRow for processing input rows? (tjavaFlex has the "End Code" section) I have tried it with the following error: The schema from the input link "row1\" is different from the schema defined inside the component Thanks for help!
Hi Volker,
seems that tAggregateRow solves my task perfectly. Performance is high (150.000 lines within 1 second).
Since my input is already sorted I understand that tAggregateSortedRow could even be better (I guess it saves the sorting step).
tAggregateSortedRow has an additional field "Input rows count" (__ROW_COUNT__) which i don't understand. What is it for?
Regards
Günter
OK, I read the many posts regarding this issue. Seems that I should stay with the tAggregateRow.