In previous post, transformed nested structure to flat. In this post example will do the reverse, transform flat structure back to original nested format, using nested groupBy, map, mapObject and orderBy. Flat Json to Nested Json Requirements:1) nested group by
DataWeave – Transform Nested Structure to Flat using map and flatten
Nested Json to Flat Json This example show usage of DataWeave to transform nested json structure to flat json structure. i break them into step 1 and 2 to better illustrate the transformation. Input Json: After Step 1: After Step