STR_TO_MAP (Lakehouse v2)
Splits a string into key-value pairs and returns a map.
Analyze Syntax
Section titled “Analyze Syntax”func.str_to_map(<str>[, <pair_delim>, <kv_delim>])Analyze Examples
Section titled “Analyze Examples”func.str_to_map('a:1,b:2,c:3', ',', ':')
┌───────────────────────────┐│ {'a':'1','b':'2','c':'3'} │└───────────────────────────┘SQL Syntax
Section titled “SQL Syntax”STR_TO_MAP(<str>[, <pair_delim>, <kv_delim>])SQL Examples
Section titled “SQL Examples”SELECT STR_TO_MAP('a:1,b:2,c:3', ',', ':');
┌───────────────────────────┐│ {"a":"1","b":"2","c":"3"} │└───────────────────────────┘