Function Reference > Functions > SETMINVARIABLE


Sets the current value of an in-out parameter to the lower of two values: the current value of the parameter or the value you specify. Returns the new current value.
Data Integration saves the final current value in the job details. Unless overridden, it uses the saved value as the initial value of the parameter for the next task session.
When used with a string in-out parameter, SETMINVARIABLE returns the lower string based on the sort order selected for the mapping.
Use the SETMINVARIABLE function only once for each in-out parameter in a pipeline. Data Integration processes variable functions as it encounters them in the mapping. The order in which Data Integration encounters variable functions in the mapping might not be the same for every session. This could cause inconsistent results if you use the same variable function multiple times in a mapping.
You can use SETMINVARIABLE in the Expression transformation.


SETMINVARIABLE( $$Variable, value )
$$ Variable
Name of the in-out parameter you want to set. Use with in-out parameter with Min aggregation type.
The value you want Data Integration to compare against the current value of the parameter. You can enter any valid expression that evaluates to a data type compatible with the data type of the parameter.

Return Value

The lower of two values: the current value of the parameter or the value you specified. The return value is the new current value of the parameter.
When value is NULL, Data Integration returns the current value of $$Variable.