Please enable JavaScript to view this site.

The SUBTRACT function subtracts one number from another and returns the difference of the subtraction operation.

You can also use the minus sign (-) to perform this function

Category

Mathematical

Syntax

SUBTRACT(numeric_value, subtraction_value)

 

or

numeric_value - subtraction_value

 

Parameters Descriptions

numeric value  A numeric value from a source datastore field/column, user specified numeric value or the numeric result of another Function.

subtraction value  This parameter specifies the number that will be subtracted from numeric_value. This number can be from a source datastore field/column, user specified numeric value or the numeric result of another Function.

Example

Subtract the source field MIN_AGE from source field EMP_AGE and map the result to AGE_DIFF. Assume that MIN_AGE is 18 and EMP_AGE is 35.

AGE_DIFF = EMP_AGE - MIN_AGE

Returns the value of 17 and maps the result to the target field.

 

Subtract the number 50 from the number 75 and map the result to target field TGT_FLD1.

TGT_FLD1 = SUBTRACT (75, 50)

Returns the value of 25 and maps the result to the target field.