Skip to main content
ReferenceApplies to: Unified engine deployments
Nested values make it possible to carry related values in one expression. Input element and field types are resolved during planning, and backend support can be narrower than the function inventory.

Arrays

Structs and maps

struct(column, ...) derives field names from column arguments. named_struct(name, value, ...) names fields explicitly. get_field(struct, field) and alias getfield access a named field. map(key, value, ...) requires alternating key/value arguments.

Higher-order functions

transform(array, x -> expression) maps elements. filter(array, x -> predicate) keeps matching elements. exists(array, x -> predicate) tests whether any element matches. Their canonical registry names are array_transform, array_filter, and array_any_match. The lambda variable is local to its expression, and output types depend on the lambda result.
Native result transport rejects some nested ARRAY/STRUCT output columns, so these examples return scalar values. ANSI arithmetic inside lambdas can be rejected when numeric types are unresolved. Nested query expressions and nested connector writes are separate capabilities. If a nested type can be returned by SELECT, confirm that your table format and write operation also accept it before inserting it.
Last modified on November 4, 2026