You are not logged in.
I have a problem with the tFilterRow component. I don't know how to give it the following command:
If "Vorgang" is "Cancel" than do not integrate "Betrag" of "Artikel" with the same "Nummer"
-> I just want to aggregate all "Artikel" which are not cancelled!
So Talend should filter the value of "Nummer" whos "Vorgang" is "Cancel".
Pls look at my screenshot. Do you know a JAVA code for this Command?
You might create a job as the following images.
The first subjob will generate a csv file called "out.csv".
The second subjob inner join source file and out.csv in tMap.
thank you very much for your help.
I think your job is very good. But i get a nullPointException because the out file has just the value "1" or nothing in the "Storno" column.
How do I handle that if Storno is set as Integer?
I think there might be an easier way to solve your problem.
I've attached some screenshots that result in a correct result I suppose.
Hope it helps (again )
Thank you a lot for your help, the community is great!
I thing we are on the right way but i have to explain the problem more detailed:
I just want to ignore each Numbers which have a "cancel" in Vorgang. Maybe it helps you when I say that number stands for receipt Number.
the job was created to calculate the earnings. It should recognize that a receipt is canceled and do not consider it in the calculation. I can't take for grant that "Cancel", if it occurs, is the last element of a single receipt because I don't know if the shema of the file which is ~3 Gbyte big is constantly equal. I also tried what pedro told me but using a pivot is very slow with big Files..
So now I'm searchin for an Expression, that sounds like this:
Filter the key attribut "row.Number" if "row.Vorgang" of the same Number equals to "Cancel"
Maybe you can help me.
I didnt't know the "Cancel" row could be anywhere in the sequence of rows, so I used the "Last" function in the first aggregation. I've changed the job a little now. It uses the List function on the Vorgang column, which creates a comma separated list of values occurring in the Vorgang column. In the Filter component all records containing Cancel in this Vorgang column will be filtered out again, now using a String.match method with (.*)Cancel(.*) as parameter.
See the attached screenshots for more info.
I suppose this should do the job.
Hey Arno, thank you very much for your answer.
I tried your idea but now it gives me an error log:
Warning:the operation 'list_object' for the output column 'Vorgang' can't be processed because of incompatible input and/or output types
Exception in component tAggregateRow_1_AGGOUT
Number as Integer, Vorgang as String and Betrag as BigDecimal. What did I wrong?
I see where that's going wrong
You should configure the first tAggregateRow component to use "List" as function for outputcolumn Vorgang and not "List(object)".