All Functions

This page contains a comprehensive list of all available functions organized by category. Each function links to its detailed documentation page with syntax, examples, and test cases.

Function Categories


Aggregate

Functions in Aggregate Category

FunctionDescription
ANY_VALUE Returns an arbitrary value from the group.
APPROX_DISTINCT Returns the approximate number of distinct values in the group.
ARRAY_AGG Returns an array of the values in the group.
AVG Returns the average of the values in the group.
BOOL_AND Returns true if all values in the group are true.
BOOL_OR Returns true if any value in the group is true.
COUNT Returns the number of values in the group.
COUNT_DISTINCT Returns the number of distinct values in the group.
COUNT_IF Returns the number of values in the group that are true.
MAX Returns the maximum value in the group.
MAX_BY Returns the maximum value in the group by the given expression.
MIN Returns the minimum value in the group.
MIN_BY Returns the minimum value in the group by the given expression.
SUM Returns the sum of the values in the group.

Array

Functions in Array Category

FunctionDescription
ALL_FUNC Returns true if all elements in the boolean array are true.
ANY_FUNC Returns true if any element in the boolean array is true.
ARRAYS_OVERLAP Returns true if any elements are common between the two arrays.
ARRAY_AVG Returns the arithmetic mean (average) of all numeric elements in an array.
ARRAY_CONCAT_FUNC Concatenates multiple arrays into a single combined array with optional deduplication.
ARRAY_DISTINCT Returns an array with distinct elements, sorted in ascending order.
ARRAY_EXCEPT Returns the difference of two arrays using set semantics.
ARRAY_HISTOGRAM Returns a frequency histogram of values in an array as an array of value-count pairs.
ARRAY_INTERSECT Returns the intersection of two arrays using set semantics.
ARRAY_JOIN Joins the elements of an array into a single string using a specified delimiter.
ARRAY_LOOKUP Returns the value corresponding to a lookup key using parallel key-value arrays.
ARRAY_MAX Returns the largest value in an array using natural ordering.
ARRAY_MIN Returns the smallest value in an array using natural ordering.
ARRAY_NOT Returns an array with inverted boolean values (logical NOT applied to each element).
ARRAY_POSITION Returns the 1-based position of the first occurrence of an element in an array.
ARRAY_REMOVE Returns an array with all occurrences of the specified element removed.
ARRAY_REVERSE Returns the reverse of an array.
ARRAY_SORT Returns the sorted version of an array.
ARRAY_SUM Returns the sum of all numeric elements in an array.
ARRAY_UNION Returns the union of two arrays, eliminating duplicate elements.
ARRAY_UNIQUE Returns an array with unique elements, removing all duplicates.
CARDINALITY Returns the number of elements in an array.
CONTAINS Returns true if the array contains the specified element.
CONTAINS_SEQUENCE Returns true if the array contains the specified sequence as a contiguous subsequence.
COSINE_SIMILARITY Calculates the cosine similarity between two arrays.
DOT_PRODUCT Calculates the dot product of two arrays.
ELEMENTS_AT_KEY Returns multiple elements at the given key from the given index, array or array of rows.
ELEMENTS_AT_POS Returns the elements at multiple specified positions in an array.
ELEMENT_AT_KEY Returns one element at the given key from the given index, array or array of rows.
ELEMENT_AT_POS Returns the element at the specified position in an array.
EUCLIDEAN_DISTANCE Calculates the Euclidean distance between two arrays.
FLATTEN_FUNC Flattens a nested array structure into a single-level array.
NONE_FUNC Returns true if no elements in the boolean array are true.
NORMALIZE Normalizes a numeric array by dividing each element by the sum of all elements.
REPEAT Creates an array by repeating an element a specified number of times.
SEQUENCE Generates an array containing a sequence of numbers from start to stop with optional step.
SLICE Returns a slice of an array with optional step parameter.
SLICE_END Returns a slice of an array using SQL-like start:end:step semantics.

Array Of Rows

Functions in Array Of Rows Category

FunctionDescription
EXTRACT Returns the extracted fields from the given expression.
INDEX_MULTI Returns an index multi computed from the given array and key.
INDEX_UNIQUE Returns an index unique computed from the given array and key.
TRANSFORM_C Transforms an array of rows using a correlated subquery
TRANSFORM_U Transforms an array of rows using UNNEST with full SQL query capabilities
UNNEST Unnests an array of rows into a table of rows
UNWRAP Returns the first field values from an array of single-field rows as a simple array.
UNWRAP_ONE Returns the value of the first field of the first element in an array of single-field rows.
ZIP_FUNC Combines multiple arrays into a single array of structured rows with named fields.

Bind

Functions in Bind Category

FunctionDescription
BIND_KEYSET Binds the given keyset to the given feature.
BIND_SQL Binds the result of the given SQL query to the given feature or features.
BIND_TABLE Binds the given array of values to the given feature or features.
BIND_VALUE Binds the given value to the given feature.
KEYSET Defines a keyset.

Business Activity

Functions in Business Activity Category

FunctionDescription
ACTIVITY_STATUS Returns the activity status between two time periods for the given activity bits
BINARY_REPRESENTATION Returns the binary representation as a string of the given activity bits
COUNT_ACTIVE Returns the number of active days for the given activity bits and time period
FROM_ACTIVITY_BITS Returns the activity dates for the given activity bits and date reference.
IS_ACTIVE Returns whether the given activity bits is active for the given time period
RECENCY Returns the number of days since the last active day for the given activity bits
TO_ACTIVITY_BITS Returns the activity bits for the given array of activity dates and date reference.
UPDATE_ACTIVITY_BIT Returns the activity bits for the given activity bits and whether the current day is active.

Business Historical

Functions in Business Historical Category

FunctionDescription
ACCUMULATION_AT_TIME Returns the state of an accumulation of events at the given point in time.
SCD_AT_TIME Returns the state of an SCD (slowly changing dimension) value at the given point in time.

Business Simulations

Functions in Business Simulations Category

FunctionDescription
GRADUAL_ROLLOUT Returns the exposure to a new version based on the given hashing key and rollout parameters.
HASH01 Returns a value between 0 and 1 based on the given hashing key.
PROBABILITY_TO_EVENT Returns the discrete event (true or false) with the given probability based on the given hashing...
SAMPLE_GAUSSIAN Returns a value chosen from a normal distribution between two bounds based on the given hashing key.
SAMPLE_UNIFORM Returns a value uniformly chosen between two bounds based on the given hashing key.
SAMPLE_VALUE Returns a value from the given array of values and proportions based on the given hashing key.

Comparison

Functions in Comparison Category

FunctionDescription
BETWEEN Returns TRUE if a value is within a specified range (inclusive)
DISPLAYS_AS Returns TRUE if two values are not distinct, treating NULL values as comparable.
EQUALS Returns TRUE if the first value equals the second value
GREATER_THAN Returns TRUE if the first value is strictly greater than the second value
GREATER_THAN_OR_EQUALS Returns TRUE if the first value is greater than or equal to the second value
GREATEST_FUNC Returns the greatest (maximum) value from a list of arguments.
IN_LIST Returns TRUE if a value exists in a list of values.
IS_NOT_NULL Returns TRUE if the expression does NOT evaluate to NULL.
IS_NULL Returns TRUE if the expression evaluates to NULL.
LEAST_FUNC Returns the least (minimum) value from a list of arguments.
LESS_THAN Returns TRUE if the first value is strictly less than the second value
LESS_THAN_OR_EQUALS Returns TRUE if the first value is less than or equal to the second value
LIKE Returns TRUE if a string matches a specified pattern with wildcards.
NOT_BETWEEN Returns TRUE if a value is NOT within a specified range (inclusive).
NOT_DISPLAYS_AS Returns TRUE if two values are distinct, treating NULL values as comparable.
NOT_EQUALS Returns TRUE if the first value does not equal the second value
NOT_IN_LIST Returns TRUE if a value does NOT exist in a list of values.
NOT_LIKE Returns TRUE if a string does NOT match a specified pattern with wildcards.

Conditional

Functions in Conditional Category

FunctionDescription
CASE_WHEN Returns the result of the first condition that evaluates to true
CASE_WHEN_SIMPLE Returns the result corresponding to the first matching value in a simple case expression
COALESCE_FUNC Returns the first non-NULL value from a list of values
IF Returns one value if a condition is true, another if false

Constant

Functions in Constant Category

FunctionDescription
E Returns the mathematical constant e (Euler's number).
EMPTY Returns a NULL value of type EMPTY.
INFINITY Returns the floating-point representation of positive infinity.
NAN Returns the floating-point representation of NaN (Not a Number).
PI Returns the mathematical constant π (pi).
VERSION Returns the version of the featuremesh registry.

Conversion

Functions in Conversion Category

FunctionDescription
CAST Returns the given expression casted to the given type.
NULL Returns a NULL value of the given type.
SQLTYPEOF Returns the type of the given expression in the target database.
TYPEOF Returns the type of the given expression in FeatureQL.

Core

Functions in Core Category

FunctionDescription
ALIAS Defines an alias of a feature.
ENTITY Defines an entity.
EVAL_CONST Evaluates a constant formula and returns the result as a literal.
INPUT Defines an input.
MACRO Defines a macro of the given feature with the given inputs.
PREPARED_STATEMENT Defines a prepared statement of the given feature with the given inputs.
UDF Defines a UDF (user-defined function).
VALUE Defines a value.
VARIANT Defines a variant of the given feature with the given replacements in its dependencies.

Date And Time

Functions in Date And Time Category

FunctionDescription
CURRENT_TIMESTAMP [Non-deterministic] Returns the current date and time.
DATE_ADD Returns the date after adding the given value to the given timestamp.
DATE_DIFF Returns the difference between the two given timestamps in the given unit.
DATE_FORMAT Returns a string from the given timestamp and format.
DATE_PARSE Returns a timestamp from the given string and format.
DATE_TRUNC Returns the given timestamp truncated to the given unit.
EXTRACT_FROM_DATE Returns the part of the given timestamp in the given unit.
FROM_ISO8601_TIMESTAMP Returns a timestamp from the given ISO 8601 string.
FROM_UNIXTIME Returns a timestamp from the given unix timestamp (BIGINT representation of the number of seconds...
HUMAN_READABLE_SECONDS Returns a human readable string from the given number of seconds.
PARSE_DURATION Returns an interval from the given duration string.
TO_ISO8601 Returns an ISO 8601 string from the given timestamp.
TO_MILLISECONDS Returns the truncated number of milliseconds in the given interval.
TO_UNIXTIME Returns a unix timestamp (BIGINT representation of the number of seconds since 1970-01-01 00:00:00...

Json

Functions in Json Category

FunctionDescription
JSON_EXTRACT Returns the value of the given JSON path in the given JSON expression.
JSON_EXTRACT_SCALAR Returns the scalar value of the given JSON path in the given JSON expression.
JSON_FORMAT Returns the given JSON expression as a string.
JSON_PARSE Returns the given string as a JSON expression.
JSON_PARSE_AS Returns the value of a JSON expression represented as a string in the given type.

Logical

Functions in Logical Category

FunctionDescription
AND Returns true if both arguments are true.
NOT Returns true if the argument is false.
OR Returns true if at least one argument is true.

Math

Functions in Math Category

FunctionDescription
ABS Returns the absolute value of a number.
ACOS Returns the arccosine (inverse cosine) of a number in radians.
ADD Adds two numbers and returns their sum.
ASIN Returns the arcsine (inverse sine) of a number in radians.
ATAN Returns the arctangent (inverse tangent) of a number in radians.
ATAN2 Returns the arctangent of y/x, using the signs to determine the quadrant.
CBRT Returns the cube root of a number.
CEIL Rounds a number up to the nearest integer (ceiling function).
COS Returns the cosine of an angle in radians.
COSH Returns the hyperbolic cosine of a number.
DEGREES Converts an angle from radians to degrees.
DIVIDE Divides the first number by the second and returns the result as a double.
DIVIDE_TYPE Divides the first number by the second, preserving the type of the first argument.
EXP Returns e raised to the power of the given number (exponential function).
FLOOR Rounds a number down to the nearest integer (floor function).
FROM_BASE Converts a number from a specified base to decimal (base 10).
IS_FINITE Checks if a number is finite (not infinite and not NaN).
IS_INFINITE Checks if a number is infinite (positive or negative infinity).
IS_NAN Checks if a value is NaN (Not a Number).
LN Returns the natural logarithm (base e) of a number.
LOG Returns the logarithm of a number to a specified base.
MODULO Returns the remainder after dividing the first number by the second (modulo operation).
MULTIPLY Multiplies two numbers and returns their product.
POW Returns the value of a number raised to the power of another number.
RADIANS Converts an angle from degrees to radians.
RANDOM [Non-deterministic] Returns a random number in the range 0.0 <= x < 1.0
ROUND Rounds a number to the nearest integer or to a specified number of decimal places.
SIGN Returns the sign of a number: -1 for negative, 0 for zero, and 1 for positive.
SIN Returns the sine of an angle in radians.
SINH Returns the hyperbolic sine of a number.
SQRT Returns the square root of a number.
SUBSTRACT Subtracts the second number from the first and returns the result.
TAN Returns the tangent of an angle in radians.
TANH Returns the hyperbolic tangent of a number.
TO_BASE Converts a decimal number to a specified base representation.
TRUNCATE Truncates a number towards zero (removes the fractional part).
WIDTH_BUCKET Returns the bucket number for a value in a histogram with custom bin boundaries.
WIDTH_BUCKET_REGULAR Returns the bucket number for a value in equally-spaced buckets within a range.

Metadata

Functions in Metadata Category

FunctionDescription
DEPTH_RELATIVE_TO Returns the depth of the current feature relative to the given feature in the dependency DAG
IS_DOWNSTREAM_OF Returns true if the current feature is dependent of the given feature in the dependency DAG
IS_UPSTREAM_OF Returns true if the current feature is a dependency of the given feature in the dependency DAG

Row

Functions in Row Category

FunctionDescription
ADD_FIELDS Adds computed feature fields to a base row or array of rows with field bindings
ARRAY_MERGE_FUNC Merges multiple arrays of rows element-wise into a single array of combined rows
MERGE_FUNC Merges multiple row structures into a single row with combined fields

String

Functions in String Category

FunctionDescription
CHR Converts a Unicode code point to its corresponding character.
CODEPOINT Returns the Unicode code point of the first character in a string.
CONCAT_FUNC Concatenates an array of strings into a single string.
CONCAT_WS_FUNC Concatenates an array of strings with a separator between each element.
HAMMING_DISTANCE Calculates the Hamming distance between two strings of equal length.
LENGTH Returns the number of characters in a string.
LEVENSHTEIN_DISTANCE Calculates the Levenshtein (edit) distance between two strings.
LOWER Converts all characters in a string to lowercase.
LPAD Left pads a string to a specified length with a padding string.
LTRIM Removes whitespace from the left (beginning) of a string.
LUHN_CHECK Validates a string using the Luhn algorithm (modulus 10 checksum).
POSITION Returns the position of the first occurrence of a substring within a string.
REPLACE Replaces all occurrences of a substring with another substring.
REVERSE Reverses the order of characters in a string.
RPAD Right pads a string to a specified length with a padding string.
RTRIM Removes whitespace from the right (end) of a string.
SOUNDEX Converts a string to its Soundex phonetic representation.
SPLIT Splits a string into an array of substrings based on a delimiter.
SPLIT_PART Returns a specific part of a string after splitting by a delimiter.
STARTS_WITH Checks if a string starts with a specified prefix.
STRPOS Returns the position of a substring within a string, optionally finding the N-th occurrence.
SUBSTR Extracts a substring from a string starting at a specified position.
TRANSLATE Replaces characters in a string based on character-to-character mappings.
TRIM Removes whitespace from both ends of a string.
UPPER Converts all characters in a string to uppercase.
WORD_STEM Returns the stem (root form) of a word using language-specific stemming rules.

Summary

  • Total Functions: 215
  • Total Categories: 19

This documentation is automatically generated from the FeatureMesh registry.

Last update at: 2025/10/13 10:23:46