I am beginner in Talend , So need help
From the source I have ID column and I need to store the max value of ID into the context variable and use it in the query in the source in next run like as below
where clause as where ID > "+context.Max_ID+"
Please guide me how I can implement this
Suppose you have a property file which contains the last Max_ID you've queried:
When the job starts, you can get the content from this file to populate your Max_ID context variable using tFileInputDelimited + tContextLoad components:
Now you can use the current Max_ID value in your query where clause.
From the result, you have to retrieve the new max value to update the Max_ID variable (using a tJavaRow or something else).
Finally, use a tContextDump to dump all the context variables, tFilterRow to keep only the key "Max_ID" and tFileOutputDelimited to overwrite the initial property file with the new Max_ID value:
Talend named a Leader.
Kickstart your first data integration and ETL projects.
Learn how to do cool things with Context Variables
Find out how to migrate from one database to another using the Dynamic schema
Pick up some tips and tricks with Context Variables