• Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » Update based on chosen field

#1 2012-06-14 16:32:17

spinegar
Member
Registered: 2012-06-13
Posts: 23

Update based on chosen field

I am importing records using sugarCRMInput and outputting that information to another instance via sugarCRMOutput. This is working great for pulling records from one instance and inserting new records in the other. How do I take this one step further and tell it to update records in the output instance based on the name field? Ultimately what I would like to do is match based on the name column for updates and if no record is found do an insert. Can anyone advise me on how to accomplish this?

Offline

#2 2012-06-14 23:31:45

vgalopin
Talend team
Registered: 2009-04-15
Posts: 442
Website

Re: Update based on chosen field

Hi,

I don't think there's any settings to do that.

So what you would have to do is take the data from your 1st instance, take the data from your 2nd instance, connect them together with a Join in a tMap component, and have two output of your tMap, one for the inserts and one for the updates. Make sure your Join is an InnerJoin, and edit the option for the insert output of your tMap to "catch InnerJoin reject". That way the records that were found will go to the update, the records didn't found will go to the insert.

It would look like something like that:

                                                  tSugarCRMInput_2
                                                             |
                                                             |
                                                             v
tSugarCRMInput_1 -----------------> tMap(InnerJoin) ---------------------> tSugarCRMOutput_2 (for Updates)
                                              Catch inner join reject
                                                             |
                                                             |
                                                             v
                                                 tSugarCRMOutput_1 (for Inserts)


Vincent Galopin
US Pre-Sales Consultant
Talend US

Offline

  • Index
  •  » Talend Open Studio for Data Integration » Usage, Operation
  •  » Update based on chosen field

Board footer

Powered by FluxBB