Skip to content

Conversation

ThomasMatlak
Copy link

Provides the inverse of the apoc.map.flatten function.

Fixes #69

Adds the function apoc.map.unflatten to provide the inverse operation of apoc.map.flatten.

Proposed Changes
apoc.map.unflatten accepts a Map<String, Object> where the keys are separated with dot-notation (e.g. topLevelKey.nestedKey).
If two keys try to use conflicting types for a key (e.g. "foo": "bar" and "foo.nested": "baz"), then the function will throw a ClassCastException.

Provides the inverse of the apoc.map.flatten function.
@bradnussbaum bradnussbaum merged commit 5e7614c into 4.0 May 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Map Unflatten Function

2 participants