How to create a file with multiple objects and arrays in the dataset

Illustrated below is an example of a partial flow where a csv file gets created with a data set.

image

The below image is the data set that contains multiple objects and arrays.

To create a file with the data, the data has to be put into one object. This can be done by creating the object in a Calculator step as shown in the image below. The created object name is “data” and the dataset ( inputRecord ) being paired with the object.

image

Illustrated below is the output of the Calculator step where there is an object called “data”.

image

In the CSV writer step, the Remove Header field is ticked and saved to remove the one object ( data ) as the header in the file.

For a single object, the data structure should be in the following format for data to be written correctly.