Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

[resolved] tSendMail will send twice the same mail

Hi
See my job in attached picture.
If I don't like the tFlowMeterCatcher to tSendMail, only one email will be send.
But when both are linked like here, I receive the same email twice.
I don't see why.
Thanks a lot and have a nice day
0683p000009MEBV.jpg
Labels (2)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Not required in the way you think... talend does not understand top or bottom or direction or location of the component or subjob...
He may execute it in different way... try using three independent tJava components printing system.out.println statements and test...you will get an idea...
if you need ordered execution, then tPreJob and tPostJob and independent job will work as required in the form of order... check this also...
Vaibhav

View solution in original post

11 Replies
Anonymous
Not applicable
Author

Hi,
- Remove existing OnSubJobOk link from tFlowMeterCatcher
- Use OnSubJobOk link from your tfileInputDelimited to your SendMail component... and change the order of this link to 2
Thanks
Vaibhav
Anonymous
Not applicable
Author

Hi,
Please take a look at component reference with related scenario TalendHelpCenter:tFlowMeterCatcher.
Best regards
Sabrina
Anonymous
Not applicable
Author

Hi Sabrina and Vaibhav,
Thanks a lot for your answers.
Sorry because I am not sure to get it...
First think is I understand tFlowMeterCatcher shouldn't be on the same job then tFlowMeter.
In the component help it is said in USAGE section : "This component is the start component of a secondary Job which triggers automatically at the end of the main Job."
On the other hand, like you will see on the two pictures, whith the job designed like that, everything works well.
It's only when I link tFileList_2 with tSendMail_1 with a OnsebJobOK link that the email is send twice.
I must be missing something...
Vaibhav, when you say "change the order of the link to 2", what do you mean ?
Sorry for these questions but I just dived into Talend and I may have missed one or two things !
Thanks and have a good day.
0683p000009ME1Q.jpg 0683p000009METr.jpg
Anonymous
Not applicable
Author

Vaibhav, when you say "change the order of the link to 2", what do you mean ?
>> Click on the connector and select option ModifySubjobOk link order
Everything is fine and fair if your requirement is satisfied with whatever design you imagine...
Vaibhav
Anonymous
Not applicable
Author

Thank you very much.
Seems I don'"t have this option.
Tried to right click the connector and click on properties but nothing happens...
Yes it works. I just want to understand why there would be two email if I link tSendMail at the end...
It looks like a loop (2 iterations) but I don't see where it could be.
Frank
0683p000009METE.jpg
Anonymous
Not applicable
Author

Tried to right click the connector and click on properties but nothing happens...
>> This option is available only when you have more than one connector originating from the component or subjob
Thanks
vaibhav
Anonymous
Not applicable
Author

Got it !
One last things, if a component unlinked is at the end of the design ; does it means it will be processed at the end, and only when the whole "first linked jobs" will be dealt ?
Thanks
Anonymous
Not applicable
Author

Not required in the way you think... talend does not understand top or bottom or direction or location of the component or subjob...
He may execute it in different way... try using three independent tJava components printing system.out.println statements and test...you will get an idea...
if you need ordered execution, then tPreJob and tPostJob and independent job will work as required in the form of order... check this also...
Vaibhav
Anonymous
Not applicable
Author

Understood.
Thanks a lot