Example - 6.5

Talend Job Script Reference Guide

author
Talend Documentation Team
EnrichVersion
6.5
EnrichProdName
Talend Big Data
Talend Big Data Platform
Talend Data Fabric
Talend Data Integration
Talend Data Management Platform
Talend Data Services Platform
Talend ESB
Talend MDM Platform
Talend Real-Time Big Data Platform
task
Design and Development > Designing Jobs
EnrichPlatform
Talend CommandLine
Talend Studio

In the following example, a WHILE loop is defined to run until the number of instances reaches 6, and the instance number increments by 2 at each iteration. As a result, the task execution is triggered at every even-numbered instance and the task will be executed three times automatically.

	setSettings {
		FORLOOP : "false",
		WHILELOOP : "true",
		DECLARATION : "int i=0",
		CONDITION : "i<6",
		ITERATION : "i=i+2"
	}