Count of rejected rows in tFileinputdelimited component
hi
I want to capture the number of rejected rows from tfileinputdelimited component my workflow is as follows
tfilelist----->tfileinputdelimited----->tlogrow
|
|
tfileoutputdelimited(reject row) file is in appending mode
Now if two files are listed ,the rejected rows from 2 file will be written to tfileoutputdelimited in appending mode , i want to find out rejected rows for individual listed files. How to get the rejected values.
Does value for ((Integer)globalMap.get("tFileOutputDelimited_2_NB_LINE")) won't propagate on on component ok link
Hi,
What the expected rejected values looks like(see my pic)? Could you elaborate your case with an example with input and expected output values.
Best regards
Sabrina
Hi
I want to catch reject record by tFileinputdelimited into tfileoutputdelimited,
but i want rejected record as it is originally present in input file.
generally i am getting rejected record with adding/removing extra delimiter.
can anyone help on this
You can send the reject flow to a tMap and build an output flow for the rejected records with the same schema like the original input component. To do that connect the reject flow to a tMap. Add to your job and tFileOutputDelimited (for the rejected records) and the as schema the schema of the tFileInputDelimited (origin of your data) by copy and paste the columns in the schema editors. Now connect the tMap with the new tFileOutputDelimited and accept the target schema for this flow. Within the tMap you can adapt the reject flow schema to the new output.
hi xdshi,
don't know why talendforge not working that's why unable to login to forum so unable to post screen shot.
my log something like tfileinputdelimited---->tmap------>tmssqloutput
|
|rejectflow
tfileoutputdelimited.
file
1|xyz|123|assada4646|india|29
2|xyz|123|ass|ada|4646|india|29
3|xyz|123|assada4646|india|29
4|xyz|123|assada4646|india|29
in by reject flow second record will reject
it will be in tfileoutputdelimited something like that
2|xyz|123|ass|ada|4646
because it match schema with tfileinputdelimited in this case in reject floe we are loosing valie of last 2 column.
i want reject record as it is in original file..
OK, in this case you have to read the lines of the input file not with a tFileInputDelimited instead use the component tFileInputRow and read the whole line at once. After reading it into one schema column you need to separate the fields with tExtractDelimitedFields and of there is something wrong you can use the original input line for the reject flow.