Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi Sabrina,Thanks for your quick reply, Please could you also help me on below query,I have 18 tfileInputDelimeted files to be scheduled and how can I consolidate the status of these jobs in a single mail?Thanks & Regards,Rajendra Lella.

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi Sabrina,My query is, instead of scheduling 18 jobs individually, How can I schedule 18 tfileInputDelimeted in one job and once all these jobs are success of failure the e-mail should be sent.How is it possible? could you help me on these lines..thanks & regards,rajendra

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi,The 18 tfileInputDelimeted files are same column structure? Do you want to extract data from 18 delimited files into one output? Could you please give us more description about current situation?Best regardsSabrina

--Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi Rajendra,Better way of doing this is- Create a subjob for each file- Create one log table to write the audit information about each file- Insert all the data for execution of each job in the database table using variables- Create one master job which calls all these subjobs- Create one more job to fetch data from log table, arrange it in html table, assign its value to context variable- Use this value in tsendmail component to send mail with table contents into it..I hope you got the pointThanksVaibhav

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi,The 18 tfileInputDelimeted files are same column structure? Do you want to extract data from 18 delimited files into one output? Could you please give us more description about current situation?Best regardsSabrina

Hi Sabrina,the 18 tfileInputDelimeted files need to be transferred to different tables in a database,ex:tinputfileA \ / tableAtinputfileB _ tmap -> tableBtinputfileC / \ tableConce the job is done I need the consolidated e-mail to be sent.

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi,From your description, you can use onSubjobOk connector to trigger tsendmail .The workflow should be:tinputfileA \ / tableAtinputfileB _ tmap -> tableBtinputfileC / \ tableC | | OnSubjobOk OnSubjoberror / \ tsendmail tsendmailHere is a related forum: http://www.talendforge.org/forum/viewtopic.php?id=37101Hope it will be helpful for you. Or do you want to send an email with number of inserted/updated/deleted rows?Best regardsSabrina

--Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.

Re: Need help on how to find the no of rows inserted/updated/deleted.

Why do you need tMap in between, besides, you can have simple flow liketinputfileA-->tableA in one talend job and other flows in other jobsCall all these jobs in single master job and use sendmail component on OnSubjobOk link...or usetinputfileA-->tableA |OnSubjobOk |tinputfileB-->tableB etc...It is not a good idea to use tMap if you don't have any lookups..Vaibhav

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi,From your description, you can use onSubjobOk connector to trigger tsendmail .The workflow should be:tinputfileA \ / tableAtinputfileB _ tmap -> tableBtinputfileC / \ tableC | | OnSubjobOk OnSubjoberror / \ tsendmail tsendmailHere is a related forum: http://www.talendforge.org/forum/viewtopic.php?id=37101Hope it will be helpful for you. Or do you want to send an email with number of inserted/updated/deleted rows?Best regardsSabrina

Hi Sabrina,Thanks for your valuable help and support,Please find the details,I have 18 jobs to be executed, I learnt that the jobs can be executed one by one by making use of on job ok,Please find my query,Job 1 has executed successfully and it has inserted 20 rows in table1Job 2 has executed successfully and it has inserted 2 rows in table2Job 3 has executed successfully and it has inserted 10 rows in table3Now I have to consolidate the details and send an e-mail, which should be as belowJob1,Inserted 20 rows in table1Job2,Inserted 2 rows in table2Job3,Inserted 10 rows in table3How can I track all jobs information and populate it in tSendMail?Please could you help me on these lines?Thanks for your valuable help and support.Regards,Rajendra Lella,

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi,From your description, you can use onSubjobOk connector to trigger tsendmail .The workflow should be:tinputfileA \ / tableAtinputfileB _ tmap -> tableBtinputfileC / \ tableC | | OnSubjobOk OnSubjoberror / \ tsendmail tsendmailHere is a related forum: http://www.talendforge.org/forum/viewtopic.php?id=37101Hope it will be helpful for you. Or do you want to send an email with number of inserted/updated/deleted rows?Best regardsSabrina

Hi Sabrina,Thanks for your valuable help and support,Please find the details,I have 18 jobs to be executed, I learnt that the jobs can be executed one by one by making use of on job ok,Please find my query,Job 1 has executed successfully and it has inserted 20 rows in table1Job 2 has executed successfully and it has inserted 2 rows in table2Job 3 has executed successfully and it has inserted 10 rows in table3Now I have to consolidate the details and send an e-mail, which should be as belowJob1,Inserted 20 rows in table1Job2,Inserted 2 rows in table2Job3,Inserted 10 rows in table3How can I track all jobs information and populate it in tSendMail?Please could you help me on these lines?Thanks for your valuable help and support.Regards,Rajendra Lella,Can any one help me in this regards...?

Re: Need help on how to find the no of rows inserted/updated/deleted.

inside tSendMail component you can use following

"Inserted "+(Integer)globalMap.get("tMSSqlOutput_1_NB_LINE_INSERTED")+ rows in "+table1"+"\n"+" Inserted "+(Integer)globalMap.get("tMSSqlOutput_2_NB_LINE_INSERTED")+ rows in "+"table2"+"\n"+"Inserted "+(Integer)globalMap.get("tMSSqlOutput_3_NB_LINE_INSERTED")+ rows in "+"table3""\n"+etc(Integer)globalMap.get("tMSSqlOutput_3_NB_LINE_INSERTED") - this variable you can get using Ctrl+Space for respective output database component.Vaibhav

Re: Need help on how to find the no of rows inserted/updated/deleted.

hai XDSHIGenerate 100 records using trowgenerator and load the data into the dbWhile loading into db there must be two flows one for insertion and other for updating the existing records in the db.Output requirement:Capture the following details for that job in separate tables,a.Job start timeb.Job end timec.No of records insertedd.No of records updatede.No of records deletedf.Duration

Re: Need help on how to find the no of rows inserted/updated/deleted.

Hi prabhakaran,We usually use Nb_LINE to count the total number of records have been proceed. when inserted item is choosen, there will be a global variale such as ((Integer)globalMap.get("tDBOutput_1_NB_LINE_INSERTED")) will be avaible, which counts the total number of records have been inserted into database.The same to updated, deleted items.Here is a tstatCatcher component which is used to gather the Job processing metadata at the Job level and at the component level. Please take a look at this component reference.https://help.talend.com/search/all?query=tStatCatcher&content-lang=en

Best regards Sabrina

--Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.