Numeric Routines - 7.1

Talend Real-time Big Data Platform Studio User Guide

Talend Real-Time Big Data Platform
Talend Studio
Design and Development
Numeric routines allow you to return whole or decimal numbers in order to use them as settings in one or more Job components. To add numeric IDs, for instance.

To access the routines, double-click the Numeric category, in the system folder. The Numeric category contains several routines, notably sequence, random and convertImpliedDecimalFormat (decimal):





Returns an incremental numeric ID.

Numeric.sequence("Parameter name", start value, increment value)


Creates a sequence if it doesn't exist and attributes a new start value.

Numeric.resetSequence (Sequence Identifier, start value)


Removes a sequence.

Numeric.RemoveSequence (Sequence Identifier)


Returns a random whole number between the maximum and minimum values.

Numeric.random(minimum start value, maximum end value)


Returns a decimal with the help of an implicit decimal model.

Numeric.convertImpliedDecimalFormat ("Target Format", value to be converted)

The three routines sequence, resetSequence, and removeSequence are closely related.

  • The sequence routine is used to create a sequence identifier, named s1 by default, in the Job. This sequence identifier is global in the Job.

  • The resetSequence routine can be used to initialize the value of the sequence identifier created by sequence routine.

  • The removeSequence routine is used to remove the sequence identifier from the global variable list in the Job.

Note: When using the tRunJob component, the sequence identifier is shared by the parent Job and all child Jobs across the whole JVM. You should use unique identifier if you do not want to use it globally.