Four Stars

Audit Stats

Hello,

I have input from Mysql database. I am writing this to Sql Server database. 

Along with this, I want to store the following information in a separate table after successful job:

 

id, load_date, table_name,no_of_records_inserted, no_of_records_updated, no_of_records_rejected.

 

How can I do this?

Please help.

Thanks in advance.

 

1 REPLY
Moderator

Re: Audit Stats

Hello,

Usually, we use Nb_LINE  is used to count the total number of records have been proceed.

When this option is set to NONE, there is no a global variable for counting the total number of records have been inserted, updated, or deleted.

When inserted item is choosen, there will be a global variale such as (Integer)globalMap.get("tMSSqlOutput_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

For no_of_records_rejected, you can drag "Rejects" row from your output DB component.

Please see my screenshot for detail

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.