Skip to main content
Math functions perform arithmetic and rounding operations on numeric field values. All variadic functions accept any mix of field names and literal numbers as arguments.

Reference

Examples

Variadic arithmetic functions

ADD, SUB, MULTIPLY, and DIVIDE accept a variable number of arguments. Each argument can be either a field name or a literal number. Field names are resolved against the current row; unresolved names fall back to being treated as literal values.
For SUB and DIVIDE, the first operand is the initial value. Subsequent operands are subtracted from or divided into it in order.