One Star

execution order of tMap output branches

I've read all the post relating to the problem of setting an order for the execution of the branches originating in a tMap component. I understand there is no way to set such order but there is a sort of bizarre behaviour which is driving me crazy. In the typical situation when output table 2 has a foreign key to table 1, both taking its values from a denormalized input table. The fact is that the order of execution of the branches is table1>table2 for each batch except the last one, where the order is inverted (table1>table1). I can understand why the order should not be alterered by the user, but changing the order in the last batch seems crazy. Has anybody encountered and/or (hopefully) solved this problem? THanks!
Community Manager

Re: execution order of tMap output branches

The output branches of tMap runs parallel, if I understand you well, you are trying to insert a records both into parent table and child table, or something like 'Star schema', the solution is to use a tFlowToIterate to iterate the input records, the following topic might give you some hints.
Talend | Data Agility for Modern Business
Seventeen Stars

Re: execution order of tMap output branches

Hi shong, that is not true. The output will be produced in the order the output flows are created or better in the order they appears in the tMap. There is no real parallel output in the meaning of time.
One input dataset will be checked by the rules of the tMap to be related for every output and the output creates flow datasets starting with the first output but there is no asynchronously behavior.