Subtract

Logic name
Subtract (Document Mapper/Variable Mapper/Merge Mapper)
Function
This logic subtracts input numbers that are below the topmost input number from the topmost number and returns the result.
Data types
Location |
Type |
---|---|
First input handler |
Numeric |
Second input handler |
Numeric |
Logic output |
Numeric |
Refer to the following for details:
-
Logic specifications (Document Mapper/Variable Mapper)
-
Logic specifications (Merge Mapper)
Properties
Category |
Property |
Description |
---|---|---|
Required settings |
Input count |
Specify the number of input items as 2 or more. |
Precision |
Specify precision |
Select whether to directly specify the decimal places of precision in decimal type calculation. |
Precision |
Specified digits |
Directly specify the number of decimal places in decimal type precision. |
Precision |
Rounding |
Specify the method of rounding. |
Null processing |
Null option |
Specify how to handle the input if it contains null. |
Comment |
Comment |
You can write a description of the logic. It doesn't affect the conversion process. |
Null option
Option |
Description |
---|---|
Convert null into 0 |
Converts null to 0 and continues with the process. |
Throw exception when unable to determine/calculate/process |
Throws an exception (CalculationException) and stops the processing when the system is unable to determine/calculate/process. |
Output null if either of input handler is null |
Outputs null if the value of any input handler is null. |
Refer to the following for details:
-
Logic specifications (Document Mapper/Variable Mapper)
-
Logic specifications (Merge Mapper)
Function details
About input count
You need enter a number greater than or equal to "2" in Input count. The number of input handlers varies depending on the value of Input count.
The recommended maximum value of Input count is "100". When you subtract 100 or more numbers, use multiple Subtract logics.
Notes
-
The precision (precision after the decimal point) used by default in arithmetic operation logic is as follows:
-
For the Add/Subtract/Modulo logic, the highest precision of the input handlers is used.
Example: 189000+1.05=189001.05
-
For the Multiply logic, the sum of the precision of the input handlers is used.
Example: 189000.05*1.05=198450.0525
-
For the Divide logic, the precision of the first input handler is used.
Example: 189000.5/0.05=3780010.0
-
-
Precision and rounding are applied per input handler.
Logic sample
Mapping definition

Logic settings and processing result
The logic subtracts the value of "column[2]" from the value of "column[1]" of the input data and outputs the result.
Property settings
Property |
Setting |
---|---|
Input count |
2 |
Specify precision |
Not selected |
Specified digits |
|
Rounding |
Round to 0. |
Null option |
Convert null into 0 |
Input data
10,3 |
10,3.0 |
10.0,3 |
Output data
7 |
7.0 |
7.0 |
For a list of logics, refer to Mapper Logic Guide.