abs.php
Table of Contents
Functions
- abs() : string
- Return the absolute value of a number.
Functions
abs()
Return the absolute value of a number.
abs(string|int|float $value) : string
This helper wraps the ArangoDB AQL function ABS(value) which returns the
absolute value (unsigned value) of a number, removing any negative sign.
Example AQL usage:
ABS(-5) // returns 5
ABS(5) // returns 5
ABS(doc.temperature) // returns absolute temperature value
Parameters
- $value : string|int|float
-
Any number, positive or negative.
Tags
Return values
string —The formatted AQL expression.