abs()
This function returns the absolute value of a.
Parameters
Parameter |
Description |
a |
Value. |
Examples
Parameter a |
Result |
|
0 |
false |
true |
123 |
123 |
-123 |
123 |
123.45 |
123.45 |
-123.45 |
123.45 |
Text |
0 |
-123.450 |
123.45 |
-123.450 |
123.450 Note: If you want to preserve the number of decimal places (see also previous example), please use a suitable data type and a corresponding template for the field on which you execute the function. Here, for example, the data type BigDecimal and the template ####0.000 |