Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
DM2017
Contributor II
Contributor II

How to use strat transaction commit rollback in TALEND

I have a job which has multiple tables involved in transaction .

1>How do I use commit and rollback, Basically on which place to be used, as I have so many sub jobs connected.

2>Where to use on component OK & where to use On sub job OK. My job is working fine. But I need to know the particular use.

 

0683p000009LsVr.jpg

 

 

Kindly help.

Labels (2)
4 Replies
lojdr
Creator II
Creator II

Hello,

 

Ad 1)

Example how to implement commit -

https://help.talend.com/reader/WWQ40R_iTE5~~9VkUQrjgQ/yuU8JtnIXUBiRsJYYKOngA?section=Raa91640

Example how to implement rollback - 

https://help.talend.com/reader/WWQ40R_iTE5~~9VkUQrjgQ/7THiSA~u~mPb7PskcQONMQ

 

ad 2) OnComponentOK - for a single component check, OnSubJobOK - when you need to check that all components in the subjob finished successfully.

 

Regards
Lojdr

DM2017
Contributor II
Contributor II
Author

Ok. Thanks. But how to design when there are multiple transformation on a same job.

 

for example

tmysqlinput1>> tmp>>tmysqloutput1 

 

tmysqlinput2>> tmp>>tmysqloutput2

 

tmysqlinput3>> tmp>>tmysqloutput3

Here I need all table load happens once or none. from youe suggestion I can go for individual commit & rollback but what about whole thing.

Please suggest

lojdr
Creator II
Creator II

Hello,

 

There is no easy solution of this task. The only correct solution is to do it in one transaction to be sure that data will stay consistent. As far as I know, there is no possibility to commit several transaction as a one. It is always one by one and this can cause inconsistency.

I recommended one solution/workaround for MySQL in the following thread:

https://community.talend.com/t5/Design-and-Development/delay-commit-when-using-built-in-mode-tMysqlO...

 

Please check it and let me know.

 

Regards
Lojdr

tourdownunder
Contributor
Contributor

Unfortunately these links are dead

Ad 1)

Example how to implement commit -

https://help.talend.com/reader/WWQ40R_iTE5~~9VkUQrjgQ/yuU8JtnIXUBiRsJYYKOngA?section=Raa91640

Example how to implement rollback - 

https://help.talend.com/reader/WWQ40R_iTE5~~9VkUQrjgQ/7THiSA~u~mPb7PskcQONMQ