Mathematical
- ABS(<x>) - Calculates the absolute value of a number
- ACOS(<x>) - Calculates the arccosine of the given number
- ASIN(<x>) - Calculates the arcsine of the given number
- ATAN(<x>) - Calculates the arctangent of the given number
- ATAN2(<x>, <y>) - Calculates the ATAN2 of the given number
- CEIL(<x>) - Calculates the ceiling of the given (floating point) number
- COS(<x>) - Calculates the cosine of the given number
- DEGREES(<x>) - Converts the given radians to degrees
- DIV(<x>, <y>) - Divides x by y
- FLOOR(<x>) - Calculates the floor of the given (floating point) number
- MOD(<x>, <y>) - Returns the remainder of the division of
x
byy
- PI() - Constant of the number pi.
- POW(<x>, <y>) - Calculates
x
to the power ofy
- PROD(<x>, <y>) - Multiplies
x
withy
- RADIANS(<x>) - Converts the given degrees to radians
- ROUND(<x>) - Rounds the given (floating point) number to the nearest integer number
- SIN(<x>) - Calculates the sine of the given number
- SQRT(<x>) - Calculates the square root of
x
- SUB(<x>, <y>) - Subtracts
x
fromy
- SUM(<x>, <y>) - Calculates the sum of
x
andy
- TAN(<x>) - Calculates the tangent of x
- TRUNC(<x>) - Truncates the floating point number
Iterator
- ALL(<iteratable>, <predicate>) - Checks if the second parameter is true for all children of the first parameter.
- ANY(<iteratable>, <predicate>) - Checks if the second parameter is true for any children of the first parameter.
- FILTER(<iteratable>, <predicate>) - Filters an array with a given predicate.
- MAP(<iteratable>, <map function>) - Maps array children into another value
Boolean Algebra
- AND(<lhs>, <rhs>) - Combines the two parameters with the Boolean AND operation.
- IMPLICATION(<lhs>, <rhs>) - Combines the two parameters with the Boolean implication (->) operation.
- NOT(<x>) - Negates the Boolean value
- OR(<lhs>, <rhs>) - Combines the two parameters with the Boolean OR operation.
- XOR(<lhs>, <rhs>) - Combines the two parameters with the Boolean exclusive or (XOR) operation.
String
- CONCAT(<str1>, <str2>) - Concatenates two string values
- FINDSTR(<str>, <substr>) - Returns the position of the second string in the first string, or -1 if it is not contained.
- LEN(<str>) - Returns the length of the passed string
- LOWER(<str>) - Converts the given string to lower case
- LTRIM(<str>) - Trims all whitespace to the left of the string
- REGEX(<str>, <regexp>) - Checks whether
str
matches the regular expressionregexp
- REGEX_EXTRACT(<str>, <regexp>) - Matches all
regexp
instr
and returns them. - REGEX_EXTRACT_FIRST(<str>, <regexp>) - Matches first
regexp
instr
and returns it. - REGEX_REPLACE(<str>, <regexp>, <replace>) - Replaces all matches of
regexp
instr
withreplace
- RTRIM(<str>) - Trims all whitespace to the right of the string
- SCONTAINS(<str>, <substr>) - Checks whether
str
containssubstr
- SPLIT(<str>, <delimiter>) - Splits a given string by the supplied delimiter
- STARTSWITH(<str>, <substr>) - Checks whether
str
starts withsubstr
- SUBSTR(<str>, <start>, (<length>)) - Returns a substring of
str
fromstart
withend
characters. - UPPER(<str>) - Converts the given string to upper case
Comparison
- EQUAL(<lhs>, <rhs>) - Checks if the given parameters have the same values.
- GREATER(<lhs>, <rhs>) - Checks if
lhs
is greater thanrhs
. - GREATEREQ(<lhs>, <rhs>) - Checks if
lhs
is greater or equal thanrhs
. - LESS(<lhs>, <rhs>) - Checks if
lhs
is less thanrhs
. - LESSEQ(<lhs>, <rhs>) - Checks if
lhs
is less or equal thanrhs
. - UNEQUAL(<lhs>, <rhs>) - Checks if the given parameters do not have the same values.
Type
- EXISTS(<x>) - Checks if the given attribute exists.
- FALSY(<x>) - Checks whether the given value is falsy.
- ISARRAY(<x>) - Checks whether the attribute is of type array
- ISBOOL(<x>) - Checks whether the attribute is of type Bool
- ISNULL(<x>) - Checks whether the attribute is of type null
- ISNUMBER(<x>) - Checks whether the attribute is of numerical type
- ISOBJECT(<x>) - Checks whether the attribute is of type object
- ISSTRING(<x>) - Checks whether the attribute is of type string
- TRUTHY(<x>) - Checks whether the given value is truthy.
- TYPE() - Returns the type of the given attribute
Metadata
- FILENAME() - Returns the filename (with full path), or “[PROJECTION]” if the document was projected
- FILEPOSEND() - Returns the end position of the document, within the file.
- FILEPOSSTART() - Returns the starting position of the document, within the file.
- ID() - Returns the internal unique ID of the document.
- NOW() - Returns the current UNIX timestamp in milliseconds
Cast
- FLOAT(<x>) - Casts the given value to floating point
- INT(<x>) - Casts/Parses the given value to integer
- STRING(<x>, (<jsonify>)) - Converts an atomic value to their string representation
Misc
- HASH(<x>) - Computes a hash value of the given value
- SEQNUM() - Returns a sequential number for every document in the collection
Array
- IN(<element>, <array>) - Checks whether the
element
is contained in thearray
- SIZE(<arr>) - Returns the size of the array
Object
- LISTATTRIBUTES(<obj>) - Returns a list of all member names in the given object
- MEMCOUNT(<obj>) - Returns the number of members in the object