One Star

Incremental Loading of multiple Tables

I am fairly new to Talend. My objective here is to load some incremental data (inserts/updates) from mysql source DB (8 or 10 tables) to a target mysql DB. In the process I am using a number of context variables to insert/update metadata into one or two reference tables that will hep track things like load job id, number of rows inserted or updated, load date etc. So I used one source table for now and it seems like I am able to successfully do a POC. I have created around 3 sub jobs for one table from start to end.
Now I have to the same thing for 8 more tables. What should be a good practice? Should I just use this one job to handle all the tables? Or Should I create separate jobs for each table? I still need to figure out best ways to handle the exceptional scenarios or any errors during the loading. Any guidance here will be appreciated.
Thanks,
Asher.
2 REPLIES
Seventeen Stars

Re: Incremental Loading of multiple Tables

You should create one job per table.
You should track the progress of the loading an memorize the most recent (or latest) timestamp or identifier and start with it in the next job run.
You should limit the datasets you transfer from source to target to a reasonable limit (e.g. 1Mio) to avoid resource problems.
You should call the job as long as the job transfers datasets (if the limit will not be reached you have successfully transferred all data.
You should do one transfer within a transaction.
This way you can do jobs which are restartable and finish the task in predictable time.
Moderator

Re: Incremental Loading of multiple Tables

Hi,
To achieve Incremental Loading in talend , you can also use Talend CDC (Changed Data Capture) which can inform your job about change.
TalendHelpCenter:CDC architectural.
TalendHelpCenter:Change Data Capture CDC is easy with Talend Studio.
So far, Talend CDC (Changed Data Capture) is only available in Talend Enterprise Subscription Version.
Best regards
Sabrina
--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.