Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Function

nest_dotted — transform fields in a record with dotted names to nested records

Synopsis

nest_dotted(val: record) -> record

Description

The nest_dotted function returns a copy of val with all dotted field names converted into nested records.

Examples


# spq
values nest_dotted(this)
# input
{"a.b.c":"foo"}
# expected output
{a:{b:{c:"foo"}}}