Get started
Load & manage data
Work with data
Administration
Reference & resources
CLUSTER BY
mask
ROW FILTER
Updated Nov 01, 2024
Send us feedback
map_from_entries
Applies to: Databricks SQL Databricks Runtime
Creates a map created from the specified array of entries.
map_from_entries(expr)
expr: An ARRAY expression of STRUCT with two fields.
expr
A MAP where keys are the first field of the structs and values the second. There must be no duplicates or nulls in the first field (the key).
> SELECT map_from_entries(array(struct(1, 'a'), struct(2, 'b'))); {1 -> a, 2 -> b}
map function
map_concat function
map_entries function
map_filter function
map_from_arrays function
map_keys function
map_values function
map_zip_with function