• Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » [resolved] Rollback on duplicate key

#1 2009-08-11 17:15:54

baris.evrim
New member
Registered: 2009-08-11
Posts: 7

[resolved] Rollback on duplicate key

Tags: [commit, rollback]

I am trying to test talend's rollback mechanism but I cannot make it work.
I have searched forums, tried various things and I still cannot manage to make rollback procedure work.

I have 4 rows in a csv file and the 3rd is a duplicate row.

You can look at the screenshots for the details.

When I run the Father job I get:

Code:

Exception in component tMysqlOutput_1
com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Duplicate entry '1' for key 'PRIMARY'

and when I look at the DB I see 2 rows inserted and not rolled back. What am I missing?

Thank you for your answers


Uploaded Images

Last edited by baris.evrim (2009-08-11 18:01:33)

Offline

#2 2009-08-11 17:31:19

emaxt6
Member
Registered: 2008-08-04
Posts: 325

Re: [resolved] Rollback on duplicate key

Seems that you are using two different connections. Provide details.

Seems also that you need to rollback on the child job and not on parent unless you are using a "shared" connection ( new feature of talend ) between parent and child.

bye

Offline

#3 2009-08-11 17:39:11

baris.evrim
New member
Registered: 2009-08-11
Posts: 7

Re: [resolved] Rollback on duplicate key

@emaxt6: Thank you for your quick answer. They are sharing the same connection.

I have included rollback mechanisms into the child job and run child job (not father), but I still get the same error and it does not roll back.

(MysqlOutput is using existing connection)

What details should I provide further?

Last edited by baris.evrim (2009-08-11 17:40:12)

Offline

#4 2009-08-11 17:53:02

emaxt6
Member
Registered: 2008-08-04
Posts: 325

Re: [resolved] Rollback on duplicate key

are you sure that you are not using auto-commit in the output component?

Offline

#5 2009-08-11 18:01:09

baris.evrim
New member
Registered: 2009-08-11
Posts: 7

Re: [resolved] Rollback on duplicate key

I have found the answer!

My table that I am trying to write is MyISAM which does not support transactions, what was I thinking?

Offline

  • Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » [resolved] Rollback on duplicate key

Board footer

Powered by FluxBB