When the transform script (Oncomplete()) is executed, is it before or after the import process ?

Fagi
Tera Contributor

Thank you for all your help.

 

I would like to use a transform map to check items after the import process, pass the information of items caught in the check to an event, and send an error mail via Notification.

For the above reasons, we would like to check all records in one process, not each record.

 

I was aware that by using transformap script(onComplete), I could check the items of all records created by the import process in the target table, but when I checked the number of rows in the target (GlideRecord object in the target table) of the transform map script with getRowCount(), the output was 0.

Is the transform script (Oncomplete()) executed after the record is created in the target table, or before?

 

As an alternative to the transform script, I am thinking of implementing a Business Rule that is executed when a record is created in the transform history table.

I would appreciate it if you could provide me with any other good ideas.

Thank you in advance.

1 件の受理された解決策

kamlesh kjmar
Mega Sage
Mega Sage

Hi @Fagi ,

 

Your assumption is right, On complete script executes once you transformation process is complete. I would suggest you GlideRecord to your Source table, there you will get to know what all target records are there that got processed based on your current import set number.

 

kamleshkjmar_0-1667886954278.png

 

 

I hope this help.

 

Please mark this helpful if this helps and Accept the solution if this solves your issue.

 

Regards,

Kamlesh

 

 

元の投稿で解決策を見る

1件の返信1

kamlesh kjmar
Mega Sage
Mega Sage

Hi @Fagi ,

 

Your assumption is right, On complete script executes once you transformation process is complete. I would suggest you GlideRecord to your Source table, there you will get to know what all target records are there that got processed based on your current import set number.

 

kamleshkjmar_0-1667886954278.png

 

 

I hope this help.

 

Please mark this helpful if this helps and Accept the solution if this solves your issue.

 

Regards,

Kamlesh